<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	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/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>MoonKat Creations &#187; accordion navigation</title>
	<atom:link href="http://www.moonkatcreations.com/tag/accordion-navigation/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.moonkatcreations.com</link>
	<description>Not just another WordPress blog about web design</description>
	<lastBuildDate>Tue, 27 Jul 2010 04:50:06 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.1</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Show/hide function for questions and answers</title>
		<link>http://www.moonkatcreations.com/web-design/jquery/showhide-function-for-questions-and-answers/</link>
		<comments>http://www.moonkatcreations.com/web-design/jquery/showhide-function-for-questions-and-answers/#comments</comments>
		<pubDate>Thu, 30 Jul 2009 22:15:37 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[jQuery]]></category>
		<category><![CDATA[accordion navigation]]></category>
		<category><![CDATA[script]]></category>
		<category><![CDATA[toggle]]></category>

		<guid isPermaLink="false">http://www.moonkatcreations.com/?p=57</guid>
		<description><![CDATA[Here&#8217;s a neat little script that allows a question and answer type format, where the questions are all listed as links, and clicking on one toggles the visibility of the corresponding answer.
$("p").hide();
$("a").click(function () {
$(this).next("p:first").slideToggle("fast");
});
Here&#8217;s a version for lists that can be used to build an accordion navigation menu:
$("ul li ul").hide();
$("a").click(function () {
$(this).next("ul:first").slideToggle("fast");
});
Thanks to this post [...]]]></description>
			<content:encoded><![CDATA[<p>Here&#8217;s a neat little script that allows a question and answer type format, where the questions are all listed as links, and clicking on one toggles the visibility of the corresponding answer.</p>
<pre>$("p").hide();
$("a").click(function () {
$(this).next("p:first").slideToggle("fast");
});</pre>
<p>Here&#8217;s a version for lists that can be used to build an accordion navigation menu:</p>
<pre>$("ul li ul").hide();
$("a").click(function () {
$(this).next("ul:first").slideToggle("fast");
});</pre>
<p>Thanks to this post on Stackoverflow for the inspiration:</p>
<p>http://stackoverflow.com/questions/248320/using-this-with-jquery-selectors/248335</p>
<p>My selectors allow you to have multiple questions listed on one page. The answers given to the question on Stackoverflow only allowed for one, since, if clicked, it would toggle ALL of the paragraphs simultaneously.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.moonkatcreations.com/web-design/jquery/showhide-function-for-questions-and-answers/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
