<?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>die musterdenker &#187; javascript</title>
	<atom:link href="http://www.musterdenker.de/tag/javascript/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.musterdenker.de</link>
	<description></description>
	<lastBuildDate>Sun, 11 Apr 2010 18:07:10 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Accordion Content script &#8211; ddaccordion / collapse all</title>
		<link>http://www.musterdenker.de/2009/05/accordion-content-script-ddaccordion-collapse-all/</link>
		<comments>http://www.musterdenker.de/2009/05/accordion-content-script-ddaccordion-collapse-all/#comments</comments>
		<pubDate>Sun, 31 May 2009 10:58:50 +0000</pubDate>
		<dc:creator>mathias</dc:creator>
				<category><![CDATA[Hints&CodeSnippits]]></category>
		<category><![CDATA[javascript]]></category>

		<guid isPermaLink="false">http://www.musterdenker.de/?p=126</guid>
		<description><![CDATA[To build a @accordion@ like navigfation menu I used the script ddaccordion by DynamicDrive. Alltogether a nice script, but somehow one feature is missing/not working.
My menu is expanding on mouseover and although there is always only one item expaneded thw whole menu will not collapse when I &#8220;mouseleave&#8221; the last menu entry. As the menu [...]]]></description>
			<content:encoded><![CDATA[<p>To build a @accordion@ like navigfation menu I used the script <a href="http://www.dynamicdrive.com/dynamicindex17/ddaccordion.htm" target="_blank">ddaccordion </a>by DynamicDrive. Alltogether a nice script, but somehow one feature is missing/not working.</p>
<p>My menu is expanding on mouseover and although there is always only one item expaneded thw whole menu will not collapse when I &#8220;mouseleave&#8221; the last menu entry. As the menu blends over half of my page it has to collapse. As I couldn&#8217;t find a solution anywhere I added 3 lines of code to the ddacordion.js script. Go to line 166 (app.) directly after:</p>

<div class="wp_codebox_msgheader wp_codebox_hide"><span class="right"><sup><a href="http://www.ericbess.com/ericblog/2008/03/03/wp-codebox/#examples" target="_blank" title="WP-CodeBox HowTo?"><span style="color: #99cc00">?</span></a></sup></span><span class="left"><a href="javascript:;" onclick="javascript:showCodeTxt('p126code3'); return false;">View Code</a> JS</span><div class="codebox_clear"></div></div><div class="wp_codebox"><table width="100%" ><tr id="p1263"><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
</pre></td><td class="code" id="p126code3"><pre class="js" style="font-family:monospace;">$('.'+config[&quot;headerclass&quot;]).bind(config.revealtype, function(){
	if (config.revealtype==&quot;mouseenter&quot;){
		ddaccordion.expandone(config[&quot;headerclass&quot;], parseInt($(this).attr(&quot;headerindex&quot;)))
	}
	else{
		$(this).trigger(&quot;evt_accordion&quot;)
		return false //cancel default click behavior
	}
})</pre></td></tr></table></div>

<p>Add the following lines:</p>

<div class="wp_codebox_msgheader wp_codebox_hide"><span class="right"><sup><a href="http://www.ericbess.com/ericblog/2008/03/03/wp-codebox/#examples" target="_blank" title="WP-CodeBox HowTo?"><span style="color: #99cc00">?</span></a></sup></span><span class="left"><a href="javascript:;" onclick="javascript:showCodeTxt('p126code4'); return false;">View Code</a> JS</span><div class="codebox_clear"></div></div><div class="wp_codebox"><table width="100%" ><tr id="p1264"><td class="line_numbers"><pre>1
2
3
4
</pre></td><td class="code" id="p126code4"><pre class="js" style="font-family:monospace;">if (config.revealtype==&quot;mouseenter&quot;){
$('.'+config[&quot;headerclass&quot;]).bind(&quot;mouseleave&quot;, function(){
	ddaccordion.collapseone(config[&quot;headerclass&quot;], parseInt($(this).attr(&quot;headerindex&quot;)))
})}</pre></td></tr></table></div>

<p>That&#8217;s all, please report your experience&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.musterdenker.de/2009/05/accordion-content-script-ddaccordion-collapse-all/feed/</wfw:commentRss>
		<slash:comments>30</slash:comments>
		</item>
	</channel>
</rss>

