<?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: How-To: Load JavaScript Libraries in WordPress</title>
	<atom:link href="http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/feed/" rel="self" type="application/rss+xml" />
	<link>http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/</link>
	<description>Nick Ohrn's Musings on Programming, Fitness, and Personal Projects</description>
	<lastBuildDate>Thu, 18 Mar 2010 01:31:47 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Nick Ohrn</title>
		<link>http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/comment-page-1/#comment-2938</link>
		<dc:creator>Nick Ohrn</dc:creator>
		<pubDate>Tue, 16 Mar 2010 15:57:00 +0000</pubDate>
		<guid isPermaLink="false">http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/#comment-2938</guid>
		<description>@Pedro - You wouldn&#039;t enqueue that perse.  You would just need that to print in the header:

&lt;pre&gt;&lt;code&gt;&lt;php
add_action(&#039;wp_head&#039;,&#039;print_my_script&#039;);
function print_my_script() {
  echo &quot;&lt;script type=&quot;text/javascript&quot;&gt;var zoomImagesBase = &#039;/wp-content/plugins/wp-fancyzoom/&#039;;&lt;/script&gt;&quot;;
}&lt;/code&gt;&lt;/pre&gt;</description>
		<content:encoded><![CDATA[<p>@Pedro &#8211; You wouldn&#8217;t enqueue that perse.  You would just need that to print in the header:</p>
<pre><code>&lt;php
add_action('wp_head','print_my_script');
function print_my_script() {
  echo "&lt;script type="text/javascript"&gt;var zoomImagesBase = '/wp-content/plugins/wp-fancyzoom/';&lt;/script&gt;";
}</code></pre>
]]></content:encoded>
	</item>
	<item>
		<title>By: Pedro Candeias</title>
		<link>http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/comment-page-1/#comment-2937</link>
		<dc:creator>Pedro Candeias</dc:creator>
		<pubDate>Tue, 16 Mar 2010 14:46:53 +0000</pubDate>
		<guid isPermaLink="false">http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/#comment-2937</guid>
		<description>Hi,
I think i get the wp_enqueue_script stuff. 
But how about something like this:
var zoomImagesBase = &#039;/wp-content/plugins/wp-fancyzoom/&#039;; 
How do can i &quot;enqueue&quot; this?

Maybe i missed something.</description>
		<content:encoded><![CDATA[<p>Hi,<br />
I think i get the wp_enqueue_script stuff.<br />
But how about something like this:<br />
var zoomImagesBase = &#8216;/wp-content/plugins/wp-fancyzoom/&#8217;;<br />
How do can i &#8220;enqueue&#8221; this?</p>
<p>Maybe i missed something.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Raj</title>
		<link>http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/comment-page-1/#comment-2904</link>
		<dc:creator>Raj</dc:creator>
		<pubDate>Sat, 06 Mar 2010 14:17:09 +0000</pubDate>
		<guid isPermaLink="false">http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/#comment-2904</guid>
		<description>Thank you for the fantastic article Nick. I&#039;ve never come across any article discussing this topic in this detail. Great work!</description>
		<content:encoded><![CDATA[<p>Thank you for the fantastic article Nick. I&#8217;ve never come across any article discussing this topic in this detail. Great work!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Nick Ohrn</title>
		<link>http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/comment-page-1/#comment-2387</link>
		<dc:creator>Nick Ohrn</dc:creator>
		<pubDate>Wed, 30 Sep 2009 02:32:16 +0000</pubDate>
		<guid isPermaLink="false">http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/#comment-2387</guid>
		<description>@ebflute - The handle is just used in wp_enqueue_script if you&#039;ve previously registered it.  By default, WordPress registers a bunch of scripts &quot;out of the box&quot;, like jQuery and more.  You can then enqueue them by just passing the handle.</description>
		<content:encoded><![CDATA[<p>@ebflute &#8211; The handle is just used in wp_enqueue_script if you&#8217;ve previously registered it.  By default, WordPress registers a bunch of scripts &#8220;out of the box&#8221;, like jQuery and more.  You can then enqueue them by just passing the handle.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: ebflute</title>
		<link>http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/comment-page-1/#comment-2379</link>
		<dc:creator>ebflute</dc:creator>
		<pubDate>Tue, 29 Sep 2009 06:02:06 +0000</pubDate>
		<guid isPermaLink="false">http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/#comment-2379</guid>
		<description>Can you explain the handle and what it is? is it something you define when you register the script and then you can use it later in the enqueue script? I simply want to include the custom jquery script so that I can use it in one place on my custom page within wordpress (it is a fading effect I want to use in my home page). I don&#039;t need to use it in a plugin.</description>
		<content:encoded><![CDATA[<p>Can you explain the handle and what it is? is it something you define when you register the script and then you can use it later in the enqueue script? I simply want to include the custom jquery script so that I can use it in one place on my custom page within wordpress (it is a fading effect I want to use in my home page). I don&#8217;t need to use it in a plugin.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: MyWebmasterTips</title>
		<link>http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/comment-page-1/#comment-2374</link>
		<dc:creator>MyWebmasterTips</dc:creator>
		<pubDate>Mon, 28 Sep 2009 03:54:13 +0000</pubDate>
		<guid isPermaLink="false">http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/#comment-2374</guid>
		<description>Great information man, I finally know that I just simply need to use the wp_enqueue command to get my javascript file to work properly.</description>
		<content:encoded><![CDATA[<p>Great information man, I finally know that I just simply need to use the wp_enqueue command to get my javascript file to work properly.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Nick Ohrn</title>
		<link>http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/comment-page-1/#comment-2307</link>
		<dc:creator>Nick Ohrn</dc:creator>
		<pubDate>Tue, 08 Sep 2009 18:02:58 +0000</pubDate>
		<guid isPermaLink="false">http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/#comment-2307</guid>
		<description>Thanks for the tip, Mark.</description>
		<content:encoded><![CDATA[<p>Thanks for the tip, Mark.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mark Jaquith</title>
		<link>http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/comment-page-1/#comment-2306</link>
		<dc:creator>Mark Jaquith</dc:creator>
		<pubDate>Tue, 08 Sep 2009 13:56:40 +0000</pubDate>
		<guid isPermaLink="false">http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/#comment-2306</guid>
		<description>To get the URL of the current plugin&#039;s directory, use &lt;code&gt;plugin_dir_url( __FILE__ )&lt;/code&gt;

It&#039;ll work in more situations.</description>
		<content:encoded><![CDATA[<p>To get the URL of the current plugin&#8217;s directory, use <code>plugin_dir_url( __FILE__ )</code></p>
<p>It&#8217;ll work in more situations.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: mores</title>
		<link>http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/comment-page-1/#comment-2285</link>
		<dc:creator>mores</dc:creator>
		<pubDate>Fri, 28 Aug 2009 15:25:57 +0000</pubDate>
		<guid isPermaLink="false">http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/#comment-2285</guid>
		<description>Update: the strange thing is, when I add ONLY
wp_enqueue_script(&#039;jquery-color&#039;)
, it still loads jquery. Not the color plugin, but jQuery itself.

Strange, strange.</description>
		<content:encoded><![CDATA[<p>Update: the strange thing is, when I add ONLY<br />
wp_enqueue_script(&#8216;jquery-color&#8217;)<br />
, it still loads jquery. Not the color plugin, but jQuery itself.</p>
<p>Strange, strange.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: mores</title>
		<link>http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/comment-page-1/#comment-2284</link>
		<dc:creator>mores</dc:creator>
		<pubDate>Fri, 28 Aug 2009 15:22:34 +0000</pubDate>
		<guid isPermaLink="false">http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/#comment-2284</guid>
		<description>my email came back, undeliverable.
Basically, I just have this


in my header.php right before the wp_head() call.</description>
		<content:encoded><![CDATA[<p>my email came back, undeliverable.<br />
Basically, I just have this</p>
<p>in my header.php right before the wp_head() call.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Nick Ohrn</title>
		<link>http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/comment-page-1/#comment-2280</link>
		<dc:creator>Nick Ohrn</dc:creator>
		<pubDate>Thu, 27 Aug 2009 22:02:02 +0000</pubDate>
		<guid isPermaLink="false">http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/#comment-2280</guid>
		<description>@mores - Could you email me a code sample - me [at] nickohrn.com</description>
		<content:encoded><![CDATA[<p>@mores &#8211; Could you email me a code sample &#8211; me [at] nickohrn.com</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: mores</title>
		<link>http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/comment-page-1/#comment-2279</link>
		<dc:creator>mores</dc:creator>
		<pubDate>Thu, 27 Aug 2009 20:38:15 +0000</pubDate>
		<guid isPermaLink="false">http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/#comment-2279</guid>
		<description>Thanks for the info. I managed to get jquery to load, but the other files refuse to load. I need jquery-color too, and neither placing the code in header.php nor in functions.php will load jquery-color. Any ideas?
WP 2.8.4, btw</description>
		<content:encoded><![CDATA[<p>Thanks for the info. I managed to get jquery to load, but the other files refuse to load. I need jquery-color too, and neither placing the code in header.php nor in functions.php will load jquery-color. Any ideas?<br />
WP 2.8.4, btw</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Nick Ohrn</title>
		<link>http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/comment-page-1/#comment-2088</link>
		<dc:creator>Nick Ohrn</dc:creator>
		<pubDate>Wed, 10 Jun 2009 20:28:18 +0000</pubDate>
		<guid isPermaLink="false">http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/#comment-2088</guid>
		<description>@Gyroscopic - To use wp_enqueue_script ( or wp_enqueue_style ) in a theme, you just have to make sure you call that function before wp_head().  You could also put the function call in your theme&#039;s functions.php file.</description>
		<content:encoded><![CDATA[<p>@Gyroscopic &#8211; To use wp_enqueue_script ( or wp_enqueue_style ) in a theme, you just have to make sure you call that function before wp_head().  You could also put the function call in your theme&#8217;s functions.php file.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Gyroscopic</title>
		<link>http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/comment-page-1/#comment-2086</link>
		<dc:creator>Gyroscopic</dc:creator>
		<pubDate>Wed, 10 Jun 2009 14:25:23 +0000</pubDate>
		<guid isPermaLink="false">http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/#comment-2086</guid>
		<description>Hi Nick, great post!

However, I&#039;m pretty new to WordPress and am not sure how to include this in a theme I have. Is there any more specific info to be had? You mention putting the wp_enqueue_script() in an init function but where is that?

I read above that Azizur Rahman managed to get it working in a theme, any chance of a post detailing exaclty how you did that please?

Cheers, Gyro</description>
		<content:encoded><![CDATA[<p>Hi Nick, great post!</p>
<p>However, I&#8217;m pretty new to WordPress and am not sure how to include this in a theme I have. Is there any more specific info to be had? You mention putting the wp_enqueue_script() in an init function but where is that?</p>
<p>I read above that Azizur Rahman managed to get it working in a theme, any chance of a post detailing exaclty how you did that please?</p>
<p>Cheers, Gyro</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Nick Ohrn</title>
		<link>http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/comment-page-1/#comment-1793</link>
		<dc:creator>Nick Ohrn</dc:creator>
		<pubDate>Fri, 24 Oct 2008 17:51:47 +0000</pubDate>
		<guid isPermaLink="false">http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/#comment-1793</guid>
		<description>@Tyler - Great, I&#039;m glad that it could help you out!</description>
		<content:encoded><![CDATA[<p>@Tyler &#8211; Great, I&#8217;m glad that it could help you out!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tyler</title>
		<link>http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/comment-page-1/#comment-1792</link>
		<dc:creator>Tyler</dc:creator>
		<pubDate>Fri, 24 Oct 2008 17:30:48 +0000</pubDate>
		<guid isPermaLink="false">http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/#comment-1792</guid>
		<description>Thanks, EXACTLY what I was looking for!</description>
		<content:encoded><![CDATA[<p>Thanks, EXACTLY what I was looking for!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Using jQuery with Wordpress &#171; ammon like salmon</title>
		<link>http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/comment-page-1/#comment-1780</link>
		<dc:creator>Using jQuery with Wordpress &#171; ammon like salmon</dc:creator>
		<pubDate>Wed, 15 Oct 2008 02:47:02 +0000</pubDate>
		<guid isPermaLink="false">http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/#comment-1780</guid>
		<description>[...] http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/ [...]</description>
		<content:encoded><![CDATA[<p>[...] <a href="http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/" rel="nofollow">http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/</a> [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Better script loading for WordPress &#124; CrossPixelNation</title>
		<link>http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/comment-page-1/#comment-27</link>
		<dc:creator>Better script loading for WordPress &#124; CrossPixelNation</dc:creator>
		<pubDate>Tue, 19 Aug 2008 19:26:40 +0000</pubDate>
		<guid isPermaLink="false">http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/#comment-27</guid>
		<description>[...] has a whole folder of plug-and-play libraries that are just waiting to be included with the wp_enqueue_script function.  Toss it in your functions.php file and it will inject the scripts into wp_head().  You can [...]</description>
		<content:encoded><![CDATA[<p>[...] has a whole folder of plug-and-play libraries that are just waiting to be included with the wp_enqueue_script function.  Toss it in your functions.php file and it will inject the scripts into wp_head().  You can [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ultra</title>
		<link>http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/comment-page-1/#comment-28</link>
		<dc:creator>Ultra</dc:creator>
		<pubDate>Sun, 20 Jul 2008 22:24:29 +0000</pubDate>
		<guid isPermaLink="false">http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/#comment-28</guid>
		<description>Nicely played my friend! Thanks for sharing the infos :-)</description>
		<content:encoded><![CDATA[<p>Nicely played my friend! Thanks for sharing the infos :-)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Nick Ohrn</title>
		<link>http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/comment-page-1/#comment-29</link>
		<dc:creator>Nick Ohrn</dc:creator>
		<pubDate>Thu, 03 Jul 2008 18:56:26 +0000</pubDate>
		<guid isPermaLink="false">http://nickohrn.com/loading-javascript-libraries-in-wordpress-plugins-with-wp_enqueue_script/#comment-29</guid>
		<description>@abubin - You would need to use wp_enqueue_script somewhere before the header is being added.  You could put it at the top of your header.php file if you wanted, probably.</description>
		<content:encoded><![CDATA[<p>@abubin &#8211; You would need to use wp_enqueue_script somewhere before the header is being added.  You could put it at the top of your header.php file if you wanted, probably.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
