<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="bbPress/1.0.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>Support Forum - Topic: Adding a Login/Logout Menu Item</title>
		<link>http://www.kriesi.at/support/topic/adding-a-loginlogout-menu-item</link>
		<description>Support Forum - Topic: Adding a Login/Logout Menu Item</description>
		<language>en-US</language>
		<pubDate>Thu, 20 Jun 2013 00:23:56 +0000</pubDate>
		<generator>http://bbpress.org/?v=1.0.2</generator>
		<textInput>
			<title><![CDATA[Search]]></title>
			<description><![CDATA[Search all topics from these forums.]]></description>
			<name>q</name>
			<link>http://www.kriesi.at/support/search.php</link>
		</textInput>
		<atom:link href="http://www.kriesi.at/support/rss/topic/adding-a-loginlogout-menu-item" rel="self" type="application/rss+xml" />

		<item>
			<title>Dude on "Adding a Login/Logout Menu Item"</title>
			<link>http://www.kriesi.at/support/topic/adding-a-loginlogout-menu-item#post-29565</link>
			<pubDate>Sun, 16 Oct 2011 08:47:01 +0000</pubDate>
			<dc:creator>Dude</dc:creator>
			<guid isPermaLink="false">29565@http://www.kriesi.at/support/</guid>
			<description>&#60;p&#62;Glad that I could help you :)
&#60;/p&#62;</description>
		</item>
		<item>
			<title>tbanetworkservices on "Adding a Login/Logout Menu Item"</title>
			<link>http://www.kriesi.at/support/topic/adding-a-loginlogout-menu-item#post-29546</link>
			<pubDate>Sun, 16 Oct 2011 03:23:30 +0000</pubDate>
			<dc:creator>tbanetworkservices</dc:creator>
			<guid isPermaLink="false">29546@http://www.kriesi.at/support/</guid>
			<description>&#60;p&#62;Excellent! Thanks!!!&#60;/p&#62;
&#60;p&#62;Thanks also for fixing the display of the post after I added the code snippet.&#60;/p&#62;
&#60;p&#62;I have been building my site over the past few hours and the theme is awesome :-)
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Dude on "Adding a Login/Logout Menu Item"</title>
			<link>http://www.kriesi.at/support/topic/adding-a-loginlogout-menu-item#post-29508</link>
			<pubDate>Sat, 15 Oct 2011 11:44:27 +0000</pubDate>
			<dc:creator>Dude</dc:creator>
			<guid isPermaLink="false">29508@http://www.kriesi.at/support/</guid>
			<description>&#60;p&#62;Hey,&#60;br /&#62;
the theme location for the sub menu is &#34;avia2&#34; instead of &#34;Primary&#34;.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>tbanetworkservices on "Adding a Login/Logout Menu Item"</title>
			<link>http://www.kriesi.at/support/topic/adding-a-loginlogout-menu-item#post-29487</link>
			<pubDate>Fri, 14 Oct 2011 16:20:20 +0000</pubDate>
			<dc:creator>tbanetworkservices</dc:creator>
			<guid isPermaLink="false">29487@http://www.kriesi.at/support/</guid>
			<description>&#60;p&#62;Inspired by &#60;a href=&#34;http://vanweerd.com/enhancing-your-wordpress-3-menus/&#34; rel=&#34;nofollow&#34;&#62;http://vanweerd.com/enhancing-your-wordpress-3-menus/&#60;/a&#62;&#60;/p&#62;
&#60;p&#62;I would like to add the following code to enable a &#34;Log in&#34; / &#34;Log out&#34; link but only on the Template's sub menu.&#60;/p&#62;
&#60;p&#62;The code is added to the theme's functions.php&#60;/p&#62;
&#60;p&#62;Q) Please can you tell me what this should be changed to or even suggest your preferred method:&#60;br /&#62;
if($args-&#38;gt;theme_location == 'Primary') {&#60;/p&#62;
&#60;p&#62;Thanks!&#60;br /&#62;
-----&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;function add_login_logout_link($items, $args) {

    if($args-&#38;gt;theme_location == &#38;#39;Primary&#38;#39;) {

        ob_start();
        wp_loginout(&#38;#39;index.php&#38;#39;);
        $loginoutlink = ob_get_contents();
        ob_end_clean();

        $items .= &#38;#39;
&#38;lt;li&#38;gt;&#38;#39;. $loginoutlink .&#38;#39;&#38;lt;/li&#38;gt;
&#38;#39;;

    }

    return $items;

}&#60;/code&#62;&#60;/pre&#62;</description>
		</item>

	</channel>
</rss>
