<?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 test wp_nav_menu() with Thematic?</title>
	<atom:link href="http://programming.thematic4you.com/2010/03/how-to-test-wp_nav_menu-with-thematic/feed/" rel="self" type="application/rss+xml" />
	<link>http://programming.thematic4you.com/2010/03/how-to-test-wp_nav_menu-with-thematic/</link>
	<description>Code Snippets and more ...</description>
	<lastBuildDate>Wed, 21 Sep 2011 08:20:43 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	
	<item>
		<title>By: Martijn</title>
		<link>http://programming.thematic4you.com/2010/03/how-to-test-wp_nav_menu-with-thematic/comment-page-1/#comment-61</link>
		<dc:creator>Martijn</dc:creator>
		<pubDate>Mon, 09 Aug 2010 20:51:21 +0000</pubDate>
		<guid isPermaLink="false">http://programming.thematic4you.com/?p=64#comment-61</guid>
		<description>I would like to know in what file this code needs to be placed...</description>
		<content:encoded><![CDATA[<p>I would like to know in what file this code needs to be placed&#8230;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Kiper IT-konsult</title>
		<link>http://programming.thematic4you.com/2010/03/how-to-test-wp_nav_menu-with-thematic/comment-page-1/#comment-55</link>
		<dc:creator>Kiper IT-konsult</dc:creator>
		<pubDate>Fri, 25 Jun 2010 10:41:43 +0000</pubDate>
		<guid isPermaLink="false">http://programming.thematic4you.com/?p=64#comment-55</guid>
		<description>Thanks for all your hard work, Chris!

It&#039;s great that you continue to develop Thematic for WP3. I have gotten so used to Thematic that it is hard to start on a new project without it...</description>
		<content:encoded><![CDATA[<p>Thanks for all your hard work, Chris!</p>
<p>It&#8217;s great that you continue to develop Thematic for WP3. I have gotten so used to Thematic that it is hard to start on a new project without it&#8230;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Chris</title>
		<link>http://programming.thematic4you.com/2010/03/how-to-test-wp_nav_menu-with-thematic/comment-page-1/#comment-52</link>
		<dc:creator>Chris</dc:creator>
		<pubDate>Tue, 22 Jun 2010 14:39:49 +0000</pubDate>
		<guid isPermaLink="false">http://programming.thematic4you.com/?p=64#comment-52</guid>
		<description>Thanks a lot, Gene. Will change this later today and change Thematic.</description>
		<content:encoded><![CDATA[<p>Thanks a lot, Gene. Will change this later today and change Thematic.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Gene</title>
		<link>http://programming.thematic4you.com/2010/03/how-to-test-wp_nav_menu-with-thematic/comment-page-1/#comment-51</link>
		<dc:creator>Gene</dc:creator>
		<pubDate>Mon, 21 Jun 2010 15:31:42 +0000</pubDate>
		<guid isPermaLink="false">http://programming.thematic4you.com/?p=64#comment-51</guid>
		<description>Heads up in the final WP 3.0 things changed
`add_theme_support( &#039;nav-menus&#039; );`

needs to be:

`add_theme_support( &#039;menus&#039; );`

to work properly.

-Gene</description>
		<content:encoded><![CDATA[<p>Heads up in the final WP 3.0 things changed<br />
`add_theme_support( &#8216;nav-menus&#8217; );`</p>
<p>needs to be:</p>
<p>`add_theme_support( &#8216;menus&#8217; );`</p>
<p>to work properly.</p>
<p>-Gene</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Chris</title>
		<link>http://programming.thematic4you.com/2010/03/how-to-test-wp_nav_menu-with-thematic/comment-page-1/#comment-50</link>
		<dc:creator>Chris</dc:creator>
		<pubDate>Fri, 18 Jun 2010 18:33:35 +0000</pubDate>
		<guid isPermaLink="false">http://programming.thematic4you.com/?p=64#comment-50</guid>
		<description>Thanks a lot for your help, Theo. I&#039;m currently testing Thematic against the final release of WordPress and doing some adjustments. Will post something later today.

Chris</description>
		<content:encoded><![CDATA[<p>Thanks a lot for your help, Theo. I&#8217;m currently testing Thematic against the final release of WordPress and doing some adjustments. Will post something later today.</p>
<p>Chris</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Theo Ribeiro</title>
		<link>http://programming.thematic4you.com/2010/03/how-to-test-wp_nav_menu-with-thematic/comment-page-1/#comment-49</link>
		<dc:creator>Theo Ribeiro</dc:creator>
		<pubDate>Fri, 18 Jun 2010 17:49:27 +0000</pubDate>
		<guid isPermaLink="false">http://programming.thematic4you.com/?p=64#comment-49</guid>
		<description>Hi Chris,

I was trying to implement the code above with the Final Release version of WP 3 and it didn&#039;t seem to be working. After some research, I solved the problem and &lt;a href=&quot;http://themeshaper.com/forums/topic/a-better-way-to-use-the-new-menu-in-wordpress-30-final-version&quot; rel=&quot;nofollow&quot;&gt;posted the solution on the Thematic Forums&lt;/a&gt;

I&#039;m posting the code bellow, I don&#039;t know if it can be improved any further:

&lt;code&gt;
// We declare that our theme supports wp_nav_menu()
add_theme_support( &#039;nav-menus&#039; );

// We Register the a new menu for the theme called &quot;Primary Menu&quot;
function register_primary_menu() {
	register_nav_menu( &#039;primary-menu&#039;, __( &#039;Primary Menu&#039; ) );
}
add_action( &#039;init&#039;, &#039;register_primary_menu&#039; );

// We remove the standard Thematic menu
function remove_menu() {
	remove_action(&#039;thematic_header&#039;,&#039;thematic_access&#039;,9);
}
add_action(&#039;init&#039;, &#039;remove_menu&#039;);

// We create the new wp_nav_menu called &quot;Primary Menu&quot; in our theme
function new_access() { ?&gt;
	
		&lt;a href=&quot;#content&quot; title=&quot;&quot;&gt;&lt;/a&gt;&lt;!-- .skip-link --&gt;
			
			
			 &#039;primary-menu&#039;, // we define this as being the previously registered &quot;Primary Menu&quot;    			
                          			&#039;menu_class&#039; =&gt; &#039;sf-menu&#039;, // we assign the sf-menu class to the menu ul so that superfish workds
                          			&#039;container_class&#039; =&gt; &#039;menu&#039; // we assign the menu class to the menu container div so to keep it compatible with the Thematic menu styling
                          		));
			?&gt;
	&lt;!-- #access --&gt;
&lt;?php
}
add_action(&#039;thematic_header&#039;,&#039;new_access&#039;,9);
&lt;/code&gt;</description>
		<content:encoded><![CDATA[<p>Hi Chris,</p>
<p>I was trying to implement the code above with the Final Release version of WP 3 and it didn&#8217;t seem to be working. After some research, I solved the problem and <a href="http://themeshaper.com/forums/topic/a-better-way-to-use-the-new-menu-in-wordpress-30-final-version" rel="nofollow">posted the solution on the Thematic Forums</a></p>
<p>I&#8217;m posting the code bellow, I don&#8217;t know if it can be improved any further:</p>
<p><code><br />
// We declare that our theme supports wp_nav_menu()<br />
add_theme_support( 'nav-menus' );</p>
<p>// We Register the a new menu for the theme called "Primary Menu"<br />
function register_primary_menu() {<br />
	register_nav_menu( 'primary-menu', __( 'Primary Menu' ) );<br />
}<br />
add_action( 'init', 'register_primary_menu' );</p>
<p>// We remove the standard Thematic menu<br />
function remove_menu() {<br />
	remove_action('thematic_header','thematic_access',9);<br />
}<br />
add_action('init', 'remove_menu');</p>
<p>// We create the new wp_nav_menu called "Primary Menu" in our theme<br />
function new_access() { ?&gt;</p>
<p>		&lt;a href=&quot;#content&quot; title=&quot;"&gt;<!-- .skip-link --></p>
<p>			 'primary-menu', // we define this as being the previously registered "Primary Menu"<br />
                          			'menu_class' =&gt; 'sf-menu', // we assign the sf-menu class to the menu ul so that superfish workds<br />
                          			'container_class' =&gt; 'menu' // we assign the menu class to the menu container div so to keep it compatible with the Thematic menu styling<br />
                          		));<br />
			?&gt;<br />
	<!-- #access --><br />
&lt;?php<br />
}<br />
add_action(&#039;thematic_header&#039;,&#039;new_access&#039;,9);<br />
</code></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Joe</title>
		<link>http://programming.thematic4you.com/2010/03/how-to-test-wp_nav_menu-with-thematic/comment-page-1/#comment-47</link>
		<dc:creator>Joe</dc:creator>
		<pubDate>Mon, 14 Jun 2010 17:40:42 +0000</pubDate>
		<guid isPermaLink="false">http://programming.thematic4you.com/?p=64#comment-47</guid>
		<description>actually, disregard my last comment... looks like the menu gets an ID based on the name specified in the menu name field...
</description>
		<content:encoded><![CDATA[<p>actually, disregard my last comment&#8230; looks like the menu gets an ID based on the name specified in the menu name field&#8230;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Joe</title>
		<link>http://programming.thematic4you.com/2010/03/how-to-test-wp_nav_menu-with-thematic/comment-page-1/#comment-46</link>
		<dc:creator>Joe</dc:creator>
		<pubDate>Mon, 14 Jun 2010 17:35:27 +0000</pubDate>
		<guid isPermaLink="false">http://programming.thematic4you.com/?p=64#comment-46</guid>
		<description>i changed this line:

return preg_replace(&#039;//&#039;, &#039;&#039;, $ulclass, 1);

to this:

return preg_replace(&#039;//&#039;, &#039;&#039;, $ulclass, 1);

and the menu works...  looks like the new WP menu function adds an ID called &quot;menu-main&quot;

cheers!</description>
		<content:encoded><![CDATA[<p>i changed this line:</p>
<p>return preg_replace(&#8216;//&#8217;, &#8221;, $ulclass, 1);</p>
<p>to this:</p>
<p>return preg_replace(&#8216;//&#8217;, &#8221;, $ulclass, 1);</p>
<p>and the menu works&#8230;  looks like the new WP menu function adds an ID called &#8220;menu-main&#8221;</p>
<p>cheers!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Chris</title>
		<link>http://programming.thematic4you.com/2010/03/how-to-test-wp_nav_menu-with-thematic/comment-page-1/#comment-40</link>
		<dc:creator>Chris</dc:creator>
		<pubDate>Fri, 04 Jun 2010 12:48:23 +0000</pubDate>
		<guid isPermaLink="false">http://programming.thematic4you.com/?p=64#comment-40</guid>
		<description>Thanks a lot, Perry. I&#039;ll test the current SVN copy.

Chris</description>
		<content:encoded><![CDATA[<p>Thanks a lot, Perry. I&#8217;ll test the current SVN copy.</p>
<p>Chris</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Perry</title>
		<link>http://programming.thematic4you.com/2010/03/how-to-test-wp_nav_menu-with-thematic/comment-page-1/#comment-39</link>
		<dc:creator>Perry</dc:creator>
		<pubDate>Thu, 03 Jun 2010 11:04:44 +0000</pubDate>
		<guid isPermaLink="false">http://programming.thematic4you.com/?p=64#comment-39</guid>
		<description>Hi there - just thought I would let you know that I just tried this on WP3 RC 1: the menu appears OK but the filter to add the &quot;sf-menu&quot; class to the ul doesn&#039;t seem to work.</description>
		<content:encoded><![CDATA[<p>Hi there &#8211; just thought I would let you know that I just tried this on WP3 RC 1: the menu appears OK but the filter to add the &#8220;sf-menu&#8221; class to the ul doesn&#8217;t seem to work.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

