Results 1 to 3 of 3

Thread: Chrome Menu

  1. #1
    Join Date
    Feb 2007
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Chrome Menu

    1) Script Title: Chrome CSS Drop Down Menu (v2.01)

    2) Script URL (on DD): http://www.dynamicdrive.com/dynamici...rome/index.htm

    3) Describe problem:

    Is there a way to have one of the top level menu items be appear "selected" when a page loads? Of course as the script is written one has to mouse over an item to trigger the background image change.

    I would like to reinforce to a visitor where they are on the site and be able to use the Chrome menu.

  2. #2
    Join Date
    Aug 2004
    Posts
    10,140
    Thanks
    3
    Thanked 1,008 Times in 993 Posts
    Blog Entries
    16

    Default

    Sure, inside the .css file, find and add to the line:

    Code:
    .chromestyle ul li a:hover, .chromestyle ul li a#selecteditem{
    background: url(chromebg-over.gif) center center repeat-x; /*THEME CHANGE HERE*/
    }
    Code in red is new. Then, inside your HTML, to have a particular main menu item selected, do the below:

    Code:
    <div class="chromestyle" id="chromemenu">
    <ul>
    <li><a href="http://www.dynamicdrive.com">Home</a></li>
    <li><a href="#" rel="dropmenu1" id="selecteditem">Resources</a></li>
    <li><a href="#" rel="dropmenu2">News</a></li>
    <li><a href="#" rel="dropmenu3">Search</a></li>	
    </ul>
    </div>

  3. #3
    Join Date
    Feb 2007
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Outstanding! Many many thanks.

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
  •