Part of the design of this menu is that the menu contents is regular HTML and added inline on the page, for search engine friendiness. The best way to use an external, single source to embed this content on muliple pages is via server side, such as SSI (server side includes), or in PHP, the include() function etc. Using SSI for example, you would save the BODY portion of the script in an external file:
Code:
<div class="chromestyle" id="chromemenu">
<ul>
<li><a href="http://www.dynamicdrive.com">Home</a></li>
<li><a href="#" rel="dropmenu1">Resources</a></li>
<li><a href="#" rel="dropmenu2">News</a></li>
</ul>
</div>
<!--1st drop down menu -->
<div id="dropmenu1" class="dropmenudiv">
<a href="http://www.dynamicdrive.com/">Dynamic Drive</a>
<a href="http://www.cssdrive.com">CSS Drive</a>
<a href="http://www.javascriptkit.com">JavaScript Kit</a>
</div>
<!--2nd drop down menu -->
<div id="dropmenu2" class="dropmenudiv" style="width: 150px;">
<a href="http://www.cnn.com/">CNN</a>
<a href="http://www.msnbc.com">MSNBC</a>
<a href="http://news.bbc.co.uk">BBC News</a>
</div>
<script type="text/javascript">
cssdropdown.startchrome("chromemenu")
</script>
and embed it via something like:
Code:
<!--#include virtual="/external.htm"-->
A tutorial on SSI here: http://www.javascriptkit.com/howto/ssi2.shtml
Bookmarks