<?xml version="1.0" encoding="UTF-8"?><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"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Creating Dependent WordPress Plugins</title>
	<atom:link href="http://fullthrottledevelopment.com/creating-dependent-wordpress-plugins/feed" rel="self" type="application/rss+xml" />
	<link>http://fullthrottledevelopment.com/creating-dependent-wordpress-plugins</link>
	<description>Custom WordPress Plugins</description>
	<lastBuildDate>Mon, 21 Mar 2011 17:32:08 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
	<item>
		<title>By: kyb3lion</title>
		<link>http://fullthrottledevelopment.com/creating-dependent-wordpress-plugins/comment-page-1#comment-2058</link>
		<dc:creator>kyb3lion</dc:creator>
		<pubDate>Tue, 05 Jan 2010 19:16:07 +0000</pubDate>
		<guid isPermaLink="false">http://fullthrottledevelopment.com/?p=384#comment-2058</guid>
		<description>Can someone tell me how to deactivate Akismet? I&#039;ve been looking all over the internet, and the official sites (WordPress and Akismet developers) just stone-wall the blog owners for years. </description>
		<content:encoded><![CDATA[<p>Can someone tell me how to deactivate Akismet? I&#039;ve been looking all over the internet, and the official sites (WordPress and Akismet developers) just stone-wall the blog owners for years.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: scribu</title>
		<link>http://fullthrottledevelopment.com/creating-dependent-wordpress-plugins/comment-page-1#comment-343</link>
		<dc:creator>scribu</dc:creator>
		<pubDate>Fri, 12 Jun 2009 02:00:26 +0000</pubDate>
		<guid isPermaLink="false">http://fullthrottledevelopment.com/?p=384#comment-343</guid>
		<description>Sadly, that doesn&#039;t seem to work:


register_activation_hook(__FILE__ , &#039;old_function&#039;);
function old_function() {
	add_action(&#039;plugins_loaded&#039; , &#039;new_activation_function&#039;);
}

function new_activation_function() {
	echo &quot;etcetera&quot;;
	add_option(&#039;__new_activation_function&#039;, &#039;bla&#039;);
	die;
}
</description>
		<content:encoded><![CDATA[<p>Sadly, that doesn&#8217;t seem to work:</p>
<p>register_activation_hook(__FILE__ , &#8216;old_function&#8217;);<br />
function old_function() {<br />
	add_action(&#8216;plugins_loaded&#8217; , &#8216;new_activation_function&#8217;);<br />
}</p>
<p>function new_activation_function() {<br />
	echo &#8220;etcetera&#8221;;<br />
	add_option(&#8216;__new_activation_function&#8217;, &#8216;bla&#8217;);<br />
	die;<br />
}</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Glenn</title>
		<link>http://fullthrottledevelopment.com/creating-dependent-wordpress-plugins/comment-page-1#comment-342</link>
		<dc:creator>Glenn</dc:creator>
		<pubDate>Fri, 12 Jun 2009 01:23:29 +0000</pubDate>
		<guid isPermaLink="false">http://fullthrottledevelopment.com/?p=384#comment-342</guid>
		<description>Well, we both know that doesn&#039;t exist. I&#039;m not trying to say a patch isn&#039;t necessary here... just looking for solutions until that point (I need them too).

If I&#039;m hearing you correctly to this point - and I think I am - the only place this wouldn&#039;t work for you with WP 2.8 is on the register_activation_hook(). Why not take whatever the guts of your activation hook are and postpone them a couple of seconds.

ie:
register_activation_hook( __FILE__ , &#039;old_function&#039;);
function old_function(){ 
  add_action(&#039;plugins_loaded&#039; , &#039;new_activation_function&#039;);
}

In that scenario, new_activation_function() would only be called if the plugin was being activated (that&#039;s the point, right) and, it would be called, after all the other plugins&#039; functions are available.

I understand the argument &quot;We need a patch&quot; and agree, but I believe this would work in the mean time.</description>
		<content:encoded><![CDATA[<p>Well, we both know that doesn&#8217;t exist. I&#8217;m not trying to say a patch isn&#8217;t necessary here&#8230; just looking for solutions until that point (I need them too).</p>
<p>If I&#8217;m hearing you correctly to this point &#8211; and I think I am &#8211; the only place this wouldn&#8217;t work for you with WP 2.8 is on the register_activation_hook(). Why not take whatever the guts of your activation hook are and postpone them a couple of seconds.</p>
<p>ie:<br />
register_activation_hook( __FILE__ , &#8216;old_function&#8217;);<br />
function old_function(){<br />
  add_action(&#8216;plugins_loaded&#8217; , &#8216;new_activation_function&#8217;);<br />
}</p>
<p>In that scenario, new_activation_function() would only be called if the plugin was being activated (that&#8217;s the point, right) and, it would be called, after all the other plugins&#8217; functions are available.</p>
<p>I understand the argument &#8220;We need a patch&#8221; and agree, but I believe this would work in the mean time.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: scribu</title>
		<link>http://fullthrottledevelopment.com/creating-dependent-wordpress-plugins/comment-page-1#comment-341</link>
		<dc:creator>scribu</dc:creator>
		<pubDate>Fri, 12 Jun 2009 01:10:27 +0000</pubDate>
		<guid isPermaLink="false">http://fullthrottledevelopment.com/?p=384#comment-341</guid>
		<description>Because of register_activation_hook() and the like. 

If you know of a hook that fires before register_activation_hook(), but after all plugins are loaded, please let me know.</description>
		<content:encoded><![CDATA[<p>Because of register_activation_hook() and the like. </p>
<p>If you know of a hook that fires before register_activation_hook(), but after all plugins are loaded, please let me know.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Glenn</title>
		<link>http://fullthrottledevelopment.com/creating-dependent-wordpress-plugins/comment-page-1#comment-338</link>
		<dc:creator>Glenn</dc:creator>
		<pubDate>Fri, 12 Jun 2009 00:33:54 +0000</pubDate>
		<guid isPermaLink="false">http://fullthrottledevelopment.com/?p=384#comment-338</guid>
		<description>Did you try it? It works for me. The script must go into the plugin that is dependent. 

First, switch the &quot;dependent&quot; and &quot;required&quot; plugin variables. Second, put the script in Akismet instead  of Hello Dolly and you can&#039;t activate Akismet unless Hello Dolly is activated.</description>
		<content:encoded><![CDATA[<p>Did you try it? It works for me. The script must go into the plugin that is dependent. </p>
<p>First, switch the &#8220;dependent&#8221; and &#8220;required&#8221; plugin variables. Second, put the script in Akismet instead  of Hello Dolly and you can&#8217;t activate Akismet unless Hello Dolly is activated.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: scribu</title>
		<link>http://fullthrottledevelopment.com/creating-dependent-wordpress-plugins/comment-page-1#comment-336</link>
		<dc:creator>scribu</dc:creator>
		<pubDate>Thu, 11 Jun 2009 23:58:07 +0000</pubDate>
		<guid isPermaLink="false">http://fullthrottledevelopment.com/?p=384#comment-336</guid>
		<description>That&#039;s also an interesting solution, but it doesn&#039;t solve the loading problem: 

If &quot;Hello Dolly&quot; was instead named &quot;AA Hello Dolly&quot;, it would be loaded before Akismet and not work.</description>
		<content:encoded><![CDATA[<p>That&#8217;s also an interesting solution, but it doesn&#8217;t solve the loading problem: </p>
<p>If &#8220;Hello Dolly&#8221; was instead named &#8220;AA Hello Dolly&#8221;, it would be loaded before Akismet and not work.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Glenn</title>
		<link>http://fullthrottledevelopment.com/creating-dependent-wordpress-plugins/comment-page-1#comment-340</link>
		<dc:creator>Glenn</dc:creator>
		<pubDate>Thu, 11 Jun 2009 21:03:51 +0000</pubDate>
		<guid isPermaLink="false">http://fullthrottledevelopment.com/?p=384#comment-340</guid>
		<description>Okay, so my script as it stands gets rid of the need for step 1 in your original email (here for others reading: &lt;a href=&quot;http://groups.google.com/group/wp-hackers/browse_thread/thread/e1d719a3c69713f4)&quot; rel=&quot;nofollow&quot;&gt;http://groups.google.com/group/wp-hackers/browse_...&lt;/a&gt; and it answers the problem you have in step 2. 
 
So, about the other problem: 
I added a function to Hello Dolly and then I went over to Akismet and tried to call it.  
 
I understand that its going to die if its referenced before its defined. My question is... in what scenario would that need to happen? Meaning, whatever you&#039;re trying to do when Akismet loads, why can&#039;t place it in an action and call it just a little bit later? </description>
		<content:encoded><![CDATA[<p>Okay, so my script as it stands gets rid of the need for step 1 in your original email (here for others reading: <a href="http://groups.google.com/group/wp-hackers/browse_thread/thread/e1d719a3c69713f4)" rel="nofollow">http://groups.google.com/group/wp-hackers/browse_&#8230;</a> and it answers the problem you have in step 2.</p>
<p>So, about the other problem:</p>
<p>I added a function to Hello Dolly and then I went over to Akismet and tried to call it. </p>
<p>I understand that its going to die if its referenced before its defined. My question is&#8230; in what scenario would that need to happen? Meaning, whatever you&#039;re trying to do when Akismet loads, why can&#039;t place it in an action and call it just a little bit later?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: scribu</title>
		<link>http://fullthrottledevelopment.com/creating-dependent-wordpress-plugins/comment-page-1#comment-339</link>
		<dc:creator>scribu</dc:creator>
		<pubDate>Thu, 11 Jun 2009 20:40:55 +0000</pubDate>
		<guid isPermaLink="false">http://fullthrottledevelopment.com/?p=384#comment-339</guid>
		<description>Yes, it works because the plugins aren&#039;t actually using any functions defined by the other. Try to add a new function in Hello Dolly and then call it from akismet, and then you&#039;ll see what I mean. (Akismet being the child plugin). </description>
		<content:encoded><![CDATA[<p>Yes, it works because the plugins aren&#039;t actually using any functions defined by the other. Try to add a new function in Hello Dolly and then call it from akismet, and then you&#039;ll see what I mean. (Akismet being the child plugin).</p>
]]></content:encoded>
	</item>
</channel>
</rss>

