Results 1 to 4 of 4

Thread: DD Accordion Menu issues...

  1. #1
    Join Date
    Nov 2011
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default DD Accordion Menu issues...

    1) Script Title: ddaccordion.js V 1.9 & jquery.min.js 1.4.2

    2) Script URL (on DD): http://www.oi411.com/menu/nav/ddaccordion.js

    Test Example: http://www.oi411.com/menu/

    3) Describe problem:

    I'm not very familiar with JS; with that said...


    Q1: I would like to have the sub page / nav item that was clicked highlighted ACTIVE either with a different color or icon... Can this be done?

    I can't figure this one out; I have found some posts stating that the way to do this would be to do-it at oninit & onopenclose but I'm not a JS guy and have no idea how to do this?


    Please Help? Anyone?

    Paulo
    Last edited by webpaul; 12-01-2011 at 03:44 AM. Reason: make change

  2. #2
    Join Date
    Nov 2011
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    K,

    Thanks for the reply... Yes I agree if it was for a website with a few pages I could just make the change in each page; but this will be for a site with around 100 pages and I want the menu to be changed only in one location and inserted into each page...

    I've read some articles and pointers that this could be done via JS at oninit and onopenclose but I have no idea how to make that work...

    Thanks

    Paul

  3. #3
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    30,495
    Thanks
    82
    Thanked 3,449 Times in 3,410 Posts
    Blog Entries
    12

    Default

    That answer is technically wrong because it contains a typo*. And it's also plagiarized word for word from:

    richnetapps.com/automatically_highlight_current_page_in/

    But that person does have a javascript solution that might work, so why not give it a try (paste the above address into your browser to navigate to the page), Hopefully that solution will not have typos.



    *
    Code:
    <ul>
     <li><a href="#">Link 1</a></li>
     <li><a class=".current" href="#">Link 2</a></li>
     <li><a href="#">Link 3</a></li>
     <li><a href="#">Link 4</a></li>
     </ul>
    A class name may not begin with a period. If it does it would have to be listed in the stylesheet as:

    Code:
    ..current
    which I'm pretty sure some if not all browsers would barf on.
    - John
    ________________________

    Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate

  4. #4
    Join Date
    Nov 2011
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    John,

    From my initial review of the link you provided; this seems to be exactly what I'm looking for...

    I will try to apply this functionality to my sample and see how it works.

    Thanks very much for the feedback.

    Paul

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •