PDA

View Full Version : Help with AnyLink CSS



Fisher
05-11-2009, 07:47 PM
1) Script Title: AnyLink CSS Menu 2.0

2) Script URL (on DD): http://www.dynamicdrive.com/dynamicindex1/anylinkcss.htm

I've got this working well but was wondering if someone might be able to help me out.

I am using the AnyLink CSS Menu to provide a dropdown of links for various images of a single figure (Figure 10, Sheet 1; Figure 10, Sheet2; etc.). This is working very well but I have found that if I need to use the same set of links in more than one place within a page, I have to include the same links a second time and redefine the lists as menu1 and menu2.

Is there any way to tell avoid having to duplicate these lists within the page and assign a single variable to it?

Thanks for any help and please let me know if that was not clear enough. :rolleyes:

Keith

ddadmin
05-12-2009, 01:42 AM
Are you saying you're unable to create multiple anchor links that all drop down a particular drop down menu? Something like this works for me:


<p><a href="http://www.dynamicdrive.com" class="anchorclass" rel="submenu1">Default Example</a></p>

<p>Some random text here</p>

<p><a href="http://www.dynamicdrive.com" class="anchorclass" rel="submenu1">Default Example again</a></p>


<div id="submenu1" class="anylinkcss">
<ul>
<li><a href="http://www.dynamicdrive.com/">Dynamic Drive</a></li>
<li><a href="http://www.cssdrive.com">CSS Drive</a></li>
<li><a href="http://www.javascriptkit.com">JavaScript Kit</a></li>
<li><a href="http://www.codingforums.com">Coding Forums</a></li>
<li><a href="http://www.javascriptkit.com/jsref/">JavaScript Reference</a></li>
</ul>
</div>

Fisher
05-12-2009, 11:40 AM
Are you saying you're unable to create multiple anchor links that all drop down a particular drop down menu?

This is exactly what I am wanting to do. I tried what you had yesterday but the result was the DIV disappearing when I rolled my pointer into the DIV and off of the text that was linking to it. I will double check my code again but the only way I have been able to get this to work is to add the list again and change the rel tag. Something like this:


<p><a href="http://www.dynamicdrive.com" class="anchorclass" rel="submenu1">Default Example</a></p>

<p>Some random text here</p>

<p><a href="http://www.dynamicdrive.com" class="anchorclass" rel="submenu2">Default Example again</a></p>

<div id="submenu1" class="anylinkcss">
<ul>
<li><a href="http://www.dynamicdrive.com/">Dynamic Drive</a></li>
<li><a href="http://www.cssdrive.com">CSS Drive</a></li>
<li><a href="http://www.javascriptkit.com">JavaScript Kit</a></li>
<li><a href="http://www.codingforums.com">Coding Forums</a></li>
<li><a href="http://www.javascriptkit.com/jsref/">JavaScript Reference</a></li>
</ul>
</div>

<div id="submenu2" class="anylinkcss">
<ul>
<li><a href="http://www.dynamicdrive.com/">Dynamic Drive</a></li>
<li><a href="http://www.cssdrive.com">CSS Drive</a></li>
<li><a href="http://www.javascriptkit.com">JavaScript Kit</a></li>
<li><a href="http://www.codingforums.com">Coding Forums</a></li>
<li><a href="http://www.javascriptkit.com/jsref/">JavaScript Reference</a></li>
</ul>
</div>

Twice the work for the same result. :(

ddadmin
05-12-2009, 08:09 PM
What I posted above works for me. Please post a link to the page on your site that contains the problematic script using my set up so we can check it out.