<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="bbPress/1.2" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title>WPMU DEV Community &#187; Topic: Got any template tags for Pay Per View?</title>
		<link>http://premium.wpmudev.org/forums/topic/got-any-template-tags-for-pay-per-view</link>
		<description>WPMU DEV Community &#187; Topic: Got any template tags for Pay Per View?</description>
		<language>en-US</language>
		<pubDate>Mon, 20 May 2013 08:02:18 +0000</pubDate>
		<generator>http://bbpress.org/?v=1.2</generator>
		<textInput>
			<title><![CDATA[Search]]></title>
			<description><![CDATA[Search all topics from these forums.]]></description>
			<name>q</name>
			<link>http://premium.wpmudev.org/forums/search.php</link>
		</textInput>
		<atom:link href="http://premium.wpmudev.org/forums/rss/topic/got-any-template-tags-for-pay-per-view" rel="self" type="application/rss+xml" />

		<item>
			<title>Patrick on "Got any template tags for Pay Per View?"</title>
			<link>http://premium.wpmudev.org/forums/topic/got-any-template-tags-for-pay-per-view#post-231380</link>
			<pubDate>Mon, 11 Jun 2012 12:49:33 +0000</pubDate>
			<dc:creator>Patrick</dc:creator>
			<guid isPermaLink="false">231380@http://premium.wpmudev.org/forums/</guid>
			<description><p>Yes, I forgot to mention that. On my site, it works fine with the nested shortcodes.</p>
<p>Yippee :o)
</p></description>
		</item>
		<item>
			<title>Hakan on "Got any template tags for Pay Per View?"</title>
			<link>http://premium.wpmudev.org/forums/topic/got-any-template-tags-for-pay-per-view#post-231376</link>
			<pubDate>Mon, 11 Jun 2012 12:44:11 +0000</pubDate>
			<dc:creator>Hakan</dc:creator>
			<guid isPermaLink="false">231376@http://premium.wpmudev.org/forums/</guid>
			<description><p>Thanks, that is enough for me.</p>
<p>BTW, I think you can also try without the template tag. The nested shortcodes should directly work.</p>
<p>Cheers,<br />
Hakan
</p></description>
		</item>
		<item>
			<title>Patrick on "Got any template tags for Pay Per View?"</title>
			<link>http://premium.wpmudev.org/forums/topic/got-any-template-tags-for-pay-per-view#post-231370</link>
			<pubDate>Mon, 11 Jun 2012 12:37:05 +0000</pubDate>
			<dc:creator>Patrick</dc:creator>
			<guid isPermaLink="false">231370@http://premium.wpmudev.org/forums/</guid>
			<description><p>@Hakan</p>
<p>Unfortunately, something weird is now going on with the client's site and I can't connect. Neither browsers nor FTP work. I've emailed him to alert him to the situation.</p>
<p>However, I did try on my site with the DaVinci theme and priority set at 8 as requested. It works fine.</p>
<p>:o)
</p></description>
		</item>
		<item>
			<title>Hakan on "Got any template tags for Pay Per View?"</title>
			<link>http://premium.wpmudev.org/forums/topic/got-any-template-tags-for-pay-per-view#post-231335</link>
			<pubDate>Mon, 11 Jun 2012 11:29:26 +0000</pubDate>
			<dc:creator>Hakan</dc:creator>
			<guid isPermaLink="false">231335@http://premium.wpmudev.org/forums/</guid>
			<description><p>Hi pcwriter,</p>
<p>I am glad that it works now :)</p>
<p>Can you please do me a favour and try priority as 8 too? In the new version I was already planning to make it so. Thus you won't have a plugin upgrade problem then.</p>
<p>Cheers,<br />
Hakan
</p></description>
		</item>
		<item>
			<title>Patrick on "Got any template tags for Pay Per View?"</title>
			<link>http://premium.wpmudev.org/forums/topic/got-any-template-tags-for-pay-per-view#post-231330</link>
			<pubDate>Mon, 11 Jun 2012 11:23:19 +0000</pubDate>
			<dc:creator>Patrick</dc:creator>
			<guid isPermaLink="false">231330@http://premium.wpmudev.org/forums/</guid>
			<description><p>@Hakan</p>
<p>Thank you, that works!</p>
<p>:o)
</p></description>
		</item>
		<item>
			<title>Hakan on "Got any template tags for Pay Per View?"</title>
			<link>http://premium.wpmudev.org/forums/topic/got-any-template-tags-for-pay-per-view#post-231231</link>
			<pubDate>Mon, 11 Jun 2012 01:25:59 +0000</pubDate>
			<dc:creator>Hakan</dc:creator>
			<guid isPermaLink="false">231231@http://premium.wpmudev.org/forums/</guid>
			<description><p>Hi pcwriter,</p>
<p>Try this. Please find this line in pay-per-view.php:</p>
<pre><code>add_filter( &#39;the_content&#39;, array( &#38;$this, &#39;content&#39; ), 12 );</code></pre>
<p>Replace 12 by 1.</p>
<blockquote><p>
Another thought: is there any way I can hardcode the pay-per-view (one time view) code into my template so I can avoid this nastiness with nested shortcodes in an uncooperative theme?</p>
</blockquote>
<p>Basically the wpmudev_ppw function should be doing this. However, in this theme I see that there is a priority problem.</p>
<p>Cheers,<br />
Hakan
</p></description>
		</item>
		<item>
			<title>aecnu on "Got any template tags for Pay Per View?"</title>
			<link>http://premium.wpmudev.org/forums/topic/got-any-template-tags-for-pay-per-view#post-231096</link>
			<pubDate>Sun, 10 Jun 2012 17:59:01 +0000</pubDate>
			<dc:creator>aecnu</dc:creator>
			<guid isPermaLink="false">231096@http://premium.wpmudev.org/forums/</guid>
			<description><p>Greetings pcwriter,</p>
<p>Thank you for the additional feedback, it is greatly appreciated to attempt to help get this issue resolved.</p>
<p>Hopefully the lead developer will make his way back in here soon with additional advice, if not I will ping him back in if necessary.</p>
<p>Cheers, Joe
</p></description>
		</item>
		<item>
			<title>Patrick on "Got any template tags for Pay Per View?"</title>
			<link>http://premium.wpmudev.org/forums/topic/got-any-template-tags-for-pay-per-view#post-231079</link>
			<pubDate>Sun, 10 Jun 2012 16:44:11 +0000</pubDate>
			<dc:creator>Patrick</dc:creator>
			<guid isPermaLink="false">231079@http://premium.wpmudev.org/forums/</guid>
			<description><p>@Hakan</p>
<p>Hi, and thanks for chiming in! Even after adding your nifty code to functions.php, I still can't get this darned nested shortcode to work.</p>
<p>This:<br />
<pre><code>&#60;?php if ( function_exists( &#39;wpmudev_ppw&#39; ) )
	echo wpmudev_ppw( do_shortcode(&#39;[quick-post-page]&#39;) ); ?&#62;</code></pre>
<p>...outputs exactly the same as this:<br />
<pre><code>[ppw id=&#34;8062299&#34; description=&#34;Submit Your Press Release&#34; price=&#34;10.00&#34;]
[quick-post-page]
[/ppw]</code></pre>
<p>The <em>quick-post-page</em> shortcode gets executed, but the <em>pay-per-view</em> code does not.</p>
<p>Another thought: is there any way I can hardcode the pay-per-view (one time view) code into my template so I can avoid this nastiness with nested shortcodes in an uncooperative theme?</p>
<p>:o(
</p></description>
		</item>
		<item>
			<title>Hakan on "Got any template tags for Pay Per View?"</title>
			<link>http://premium.wpmudev.org/forums/topic/got-any-template-tags-for-pay-per-view#post-231058</link>
			<pubDate>Sun, 10 Jun 2012 14:13:52 +0000</pubDate>
			<dc:creator>Hakan</dc:creator>
			<guid isPermaLink="false">231058@http://premium.wpmudev.org/forums/</guid>
			<description><p>Hi,</p>
<p>This will be available with the new version, but you can add it yourself now. Just include this code inside functions.php of your theme:</p>
<pre><code>if ( !function_exists( &#39;wpmudev_ppw&#39; ) ) {
	function wpmudev_ppw( $content=&#39;&#39;, $force=false ) {
		global $ppw, $post;
                if ( !is_object( $ppw ) )
                        return;
		if ( $content )
			return $ppw-&#62;content( $content, $force );
		else
			return $ppw-&#62;content( $post-&#62;post_content, $force );
	}
}</code></pre>
<p>Then you can use the above function to wrap the existing function generating the content. For example suppose that content is outputted with:</p>
<pre><code>echo my_page_content( );</code></pre>
<p>Now use:<br />
<pre><code>if ( function_exists( &#39;wpmudev_ppw&#39; ) )
     echo wpmudev_ppw( my_page_content() );
else
     echo my_page_content();</code></pre>
<p>Cheers,<br />
Hakan
</p></description>
		</item>
		<item>
			<title>Patrick on "Got any template tags for Pay Per View?"</title>
			<link>http://premium.wpmudev.org/forums/topic/got-any-template-tags-for-pay-per-view#post-231056</link>
			<pubDate>Sun, 10 Jun 2012 13:59:12 +0000</pubDate>
			<dc:creator>Patrick</dc:creator>
			<guid isPermaLink="false">231056@http://premium.wpmudev.org/forums/</guid>
			<description><p>@Joe</p>
<p>Thanks for pinging the dev on this puzzle! It's got me stumped.</p>
<p>I've also posted in the Solostream forum using the client's login creds, but haven't gotten a response yet. </p>
<p>Fingers crossed...</p>
<p>:o)
</p></description>
		</item>
		<item>
			<title>aecnu on "Got any template tags for Pay Per View?"</title>
			<link>http://premium.wpmudev.org/forums/topic/got-any-template-tags-for-pay-per-view#post-231041</link>
			<pubDate>Sun, 10 Jun 2012 12:23:48 +0000</pubDate>
			<dc:creator>aecnu</dc:creator>
			<guid isPermaLink="false">231041@http://premium.wpmudev.org/forums/</guid>
			<description><p>Greetings pcwriter,</p>
<p>Seems like you got your self in a theme bind on this one since the nested short codes work with the other themes as you indicated.</p>
<p>Concerning the answer I admit I do not know. </p>
<p>Therefore I will see about getting the lead developer in here with his invaluable insight to see what advice/advise he can offer us to possibly overcome this issue.</p>
<p>Though this may take a bit longer then a normal ticket, I will try to get him in here asap.</p>
<p>Cheers, Joe
</p></description>
		</item>
		<item>
			<title>Patrick on "Got any template tags for Pay Per View?"</title>
			<link>http://premium.wpmudev.org/forums/topic/got-any-template-tags-for-pay-per-view#post-231005</link>
			<pubDate>Sun, 10 Jun 2012 06:00:31 +0000</pubDate>
			<dc:creator>Patrick</dc:creator>
			<guid isPermaLink="false">231005@http://premium.wpmudev.org/forums/</guid>
			<description><p>Hi Dean</p>
<p>I'm glad you enjoyed the book!</p>
<blockquote><p>Is it possible that the slash in the second shortcode could be causing the problem</p></blockquote>
<p>No, because the first shortcode encloses some content, the slash is required to close it like the example below:<br />
[shortcode] Some content here [/shortcode]</p>
<p>The content enclosed in the pay-per-view shortcode I'm trying to run just happens to be another shortcode that launches the front-end post-form from a plugin. As that second shortcode just outputs its content, it is self-closing so requires no closing tag with a slash.
</p></description>
		</item>
		<item>
			<title>Dean Kaus on "Got any template tags for Pay Per View?"</title>
			<link>http://premium.wpmudev.org/forums/topic/got-any-template-tags-for-pay-per-view#post-230989</link>
			<pubDate>Sun, 10 Jun 2012 04:42:48 +0000</pubDate>
			<dc:creator>Dean Kaus</dc:creator>
			<guid isPermaLink="false">230989@http://premium.wpmudev.org/forums/</guid>
			<description><p>Hey @PCwriter BTW great book!  I may even get inspired to write something myself someday.<br />
I'm not even close to being at your level of coding but I did have one question about the shortcodes as you have them listed above.<br />
[payperview-shortcode] [another-shortcode] <strong>[/</strong>payperview-shortcode]<br />
Is it possible that the slash in the second shortcode could be causing the problem.  Possible in the themes it works in don't see it and the theme that doesn't work sees it as html or something.  Probably a stupid thought but it just looked out of place to me.</p>
<p>Hope life is treating you well!
</p></description>
		</item>
		<item>
			<title>Patrick on "Got any template tags for Pay Per View?"</title>
			<link>http://premium.wpmudev.org/forums/topic/got-any-template-tags-for-pay-per-view#post-230960</link>
			<pubDate>Sun, 10 Jun 2012 02:50:31 +0000</pubDate>
			<dc:creator>Patrick</dc:creator>
			<guid isPermaLink="false">230960@http://premium.wpmudev.org/forums/</guid>
			<description><p>Hi all,</p>
<p>I'm trying to implement my Pay-to-Post technique on a client's site (see <a href="http://premium.wpmudev.org/forums/topic/enable-your-users-to-pay-per-post-or-create-your-own-advertise-on-this-site-ad-system#post-201628" target="_blank">http://premium.wpmudev.org/forums/topic/enable-your-users-to-pay-per-post-or-create-your-own-advertise-on-this-site-ad-system#post-201628</a> for more)</p>
<p>The problem I'm experiencing is with nested shortcodes in the post editor of the theme he's using: WP-DaVinci from Solostream. The shortcode setup looks like this:</p>
<p>[payperview-shortcode] [another-shortcode] [/payperview-shortcode]</p>
<p>In the above scenario, only the nested self-closing shortcode gets executed, while the payperview shortcode is ignored. I've tested this setup in several other themes and it works just fine: Twenty-Eleven, Suffusion, SimpleMarket from WPMUdev, iTheme2 from Themify, Buddypress Default.</p>
<p>I've also tried to get the nested shortcodes to work in a page template, but no success.</p>
<p>Thus my question: is there a template tag that can be used/created to replace the payperview shortcode in a page template?</p>
<p>Any and all feedback would be greatly appreciated... thanks!</p>
<p>:o)
</p></description>
		</item>

	</channel>
</rss>
