Programming Tutorials Browser Tutorials Articles Struts Tutorials Hibernate Tutorials

Search: 

  Tutorial: CSS CSS Chrome CSS Drop Down Menu Tutorial

Chrome Menu is a CSS and JavaScript hybrid drop down menu. It's easy to configure and search engine friendly. The menu links is based on a list, while the drop down menus are simply regular DIV tags on page.

Tutorial Details:

Dynamic Drive DHTML Scripts- Chrome CSS Drop Down Menu
Submit FAQs Awards Usage Terms Contact
Home
New
Revised
Tools
Forums
Home Menu and Navigation CSS Based Here
Categories
Calendars
Date & Time
Document Effects
Dynamic Content
Form Effects
Games
Image Effects
Links & Tooltips
Menus & Navigation
Mouse and Cursor
Scrollers
Text Animations
User/System Preference
Window and Frames
Other
Other Sections
Script Forums
Recommend Us
Usage Terms
Free JavaScripts
Compatibility
IE5+: IE 5 and above
FF1+: Firefox 1.0+. NS6+ and FF beta are assumed as well.
Opr7+: Opera 7 and above.
Bookmark online:
Bookmark to del.icio.us
Bookmark to Furl.net
Link Back
FF1+ IE5+ Opr7+
Chrome CSS Drop Down Menu
Author: Dynamic Drive
Note: Updated Feb 1st, 06'. Added extra CSS to render optional shadow to menu in IE. Read "notes" below.
Description: We decided to create this script when we needed a compact CSS drop down menu for a project. Chrome Menu is a CSS and JavaScript hybrid drop down menu. It's easy to configure and search engine friendly. The menu links is based on a list, while the drop down menus are simply regular DIV tags on page. Thanks to JavaScript, the menu supports subtle but important effects such as delay before menu disappearance, and repositioning of the menu if too close to any one of the four corners of the window. The entire menu, including images and external files, is extremely compact, at around 6 kilobytes!
Thanks to CSS, the menu can be styled with a different "theme" easily, just by modifying a few CSS attributes and changing a couple of images' colors.
Demo:
Home
Resources
News
Search
Dynamic Drive CSS Drive JavaScript Kit Coding Forums JavaScript Reference
CNN MSNBC BBC News
Google Yahoo MSN
Directions: Simply download chromemenu.zip , which contains all the files that make up the menu:
demo.htm ( view )
chromejs/chrome.js ( view )
chrometheme/chromestyle.css ( view )
chrometheme/chromebg.gif
chrometheme/divider.gif
Note: Also included in the zip are slightly modified versions of the above ".gif" and ".css" files that create a different theme for the menu instantly.
As you can see in the source of "demo.htm", the entire mark up for the menu looks like this:
<div id="chromemenu">
<ul>
<li><a href="http://www.dynamicdrive.com">Home</a></li>
<li><a href="#" onMouseover="cssdropdown.dropit(this,event,'dropmenu1')">Resources</a></li>
<li><a href="#" onMouseover="cssdropdown.dropit(this,event,'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>
</div>
The list (
    ) above makes up the menu bar itself, while the DIVs below it are the drop down menus associated with each menu link. Note the code in red - when defining a new drop down menu, give it an arbitrary but unique ID, then pass this ID into the "onMouseover" code inside the link that will activate it. And that's it! Adding or removing new menu links or drop down menus all follow the same format as what's already shown above.
    Alternate themes
    Just by changing the colors of the two images used by the menu, plus adjust the CSS file accordingly, you can have a different look for your menu. For example:
    Blue look:
    Home
    Resources
    News
    Search
    Dynamic Drive CSS Drive JavaScript Kit Coding Forums JavaScript Reference
    CNN MSNBC BBC News
    Google Yahoo MSN
    Green look:
    Home
    Resources
    News
    Search
    Dynamic Drive CSS Drive JavaScript Kit Coding Forums JavaScript Reference
    CNN MSNBC BBC News
    Google Yahoo MSN
    Red look:
    Home
    Resources
    News
    Search
    Dynamic Drive CSS Drive JavaScript Kit Coding Forums JavaScript Reference
    CNN MSNBC BBC News
    Google Yahoo MSN
    In the zip file you downloaded above, I've included the alternate versions of the original ".gif" and ".css" files that make up the above themes. Yes I was bored :) You can easily create your own themes, just by modifying the color of the original images using any decent graphics program, by manipulating the image's Hue/Saturation properties for example.
    Notes
    Chrome CSS menu behaves slightly differently in Firefox and IE6 that's worth mentioning. Specifically:
    -In Firefox (plus Opera 8+), the letter "v" appears to the right of links in the menu bar to indicate this item drops down. You can customize or even remove this character by editing the CSS:
    #chromemenu ul li a[onMouseover]:after{ /*HTML to indicate drop down link*/
    content: " v";
    /*content: " " url(downimage.gif); /*uncomment this line to use an image instead*/
    }
    inside "chromestyle.css". IE6 or below does not support CSS2 conditional HTML, so this feature isn't visible in that browser.
    -To calm the uproaring, in IE exclusively, a light shadow is added to the drop down menu by default, via the CSS:
    filter: progid:DXImageTransform.Microsoft.Shadow(color=#CACACA,direction=135,strength=4);
    inside "chromestyle.css". Edit or remove as desired.
    Copyright © 1998-2006 Dynamic Drive. Please read Terms Of Use here before using any of the scripts.


     

    Read Tutorial at: Click here to view the tutorial

    Rate Tutorial:
    CSS CSS Chrome CSS Drop Down Menu Tutorial

    View Tutorial:
    CSS CSS Chrome CSS Drop Down Menu Tutorial

    Related Tutorials:

    Displaying 1 - 50 of about 2698 Related Tutorials.

    jQuery Drop Down Menu
    jQuery Drop Down Menu jQuery Drop Down Menu...; In this JQuery tutorial we will develop a program  to make Drop Down menu Steps to develop the Drop Down menu . Step 1:        
     
    ZF Decorate With CSS
    tutorial. First of all create a folder called css in public folder and create a file called site.css inside the css folder (public->css->site.css), now...Now Decorate it with CSS: It is obvious that we need some CSS to change
     
    CSS Designer
    CSS Designer CSS Designer...;           CSS Designer is now availabe as part of the Web Designer. JointLogic CSS Designer is an Eclipse plugin
     
    Cascading Style Sheet(CSS)
    Cascading Style Sheet(CSS) Cascading Style Sheet(CSS...; Cascading Style Sheet (CSS) is known as style sheet language, define
     
    CSS Editor
    CSS Editor CSS Editor  ... sophisticated CSS authoring functionality to the Eclipse Platform. It implements an editor that provides enhanced support for editing CSS source files
     
    Implementing CSS and JavaScript in JSP File
    Implementing CSS and JavaScript in JSP File Implementing CSS and JavaScript in JSP File    ... shows how to implement css and JavaScript in jsp. Here we have created three main
     
    Working with JavaScript & CSS
    Working with JavaScript & CSS Working with JavaScript & CSS      ..., onselect etc. For using CSS, JSF provides style and styleClass attributes
     
    Dynamic Dropdown Menu
    ; Put records from your database in a drop down menu/list box. You can apply...;head> <title>Dynamic Drop Down List</title> </head>... Dynamic Dropdown Menul Dynamic Dropdown Menu
     
    Dojo Menu and Menu Item
    Dojo Menu and Menu Item Dojo Menu and Menu Item...; In this section, you will learn about the menu and how to create it in dojo. Try Online: Menu and Menu Item Menu : This is the widget models
     
    The Role of AJAX in enhancing the user experience on the Web
    availability of user name, measure strength of password, populate drop-down boxes... but a combination of several existing technologies in a new way. These include HTML, CSS... on a menu item in some other segment. Even in case of an error in one
     
    JSF messages Tag
    the message then CSS can be used. If you want to show the error message for a component in a color and other information in different color then CSS can be helpful. Two... : It is used to set the CSS style definition for the component.  title
     
    JointLogic Web Designer
    Designer and CSS Designer. HTML Designer provides WYSIWYG authoring of HTML and XHTML... inspector and Properties view. It integrates with CSS Designer to provide rich authoring of in-line CSS and embedded style sheets. HTML Designer integrates with Eclipse
     
    XMLEspresso
    : Version 6.0.0 supports editing of DTD and CSS documents.    ... Mode for normal editing during development; XML Mode is ideal for lock down
     
    Chart Style in Flex4
    Chart Style in Flex4: In this section we will discuss the chart style. You can provide the style by using CSS. You can set the Axes style, Series style, Data Tip style and Legend style. In This section you can see how we can change
     
    How to design a water drop.
    Shadow and adjustment the settings. Drop Shadow: Go to Layer Menu > Layer... How to design a water drop.< How to design a water drop.           
     
    PHP AJAX Dropdown
    Ajax Drop-down list: In this current tutorial we will see how to connect a simple drop down menu and mysql table using php and JavaScript (Ajax as whole) and to display the related data on the screen from the table. In this tutorial
     
    Create Menu Bar in SWT
    is allowed to create a menu bar. The method setMenu() sets the pull down menu... Create Menu Bar in SWT Create Menu Bar in SWT...;   This section illustrates you how to create a menu bar
     
    Graphics Designer Jobs
    based layout, DreamWeaver,CSS and JavaScript. Developing website templates... knowledge HTML, DHTML, Adobe Photoshop, CSS, JavaScript FrontPage & Dream
     
    jQuery Tutorial
    jQuery Tutorial jQuery is a cross browser, java Script library created by  'John Resig' in 2006 with a nice motto: "Write less, do... functions DOM traversal and modification Events CSS manipulation Effects
     
    Dojo Tutorial
    DOJO Tutorial Dojo Tutorial  ...; In this tutorial, you will learn everything about the dojo. After completing the tutorial.... This advanced Dojo tutorial covers: Introduction to DOJO
     
    Photoshop Tutorial : Text Effect
    in this tutorial. Let's try Take a new file: Go to file menu and select new. A pop... to Layer menu > Layer Style > Drop shadow and adjust setting as given below...;    This is a text effect tutorial. This tutorial
     
    Mysql Drop
    The Tutorial illustrate an example from 'Mysql Drop'.To understand this example we... Mysql Drop Mysql Drop   ...;            Mysql Drop
     
    Drop Index
    with Example The Tutorial illustrate an example from Drop Index. In this example... Drop Index Drop Index   ...;            Drop Index
     
    Drop Table
    .  Understand with Example The Tutorial illustrate an example from Drop... Drop Table Drop Table   ...;            Drop Table
     
    Dojo drag and drop
    Dojo drag and drop Dojo drag and drop...; In this section, you will learn about dojo drag and drop. Drag and Drop... to be dragged and dropped,  you hold down the mouse button and drag
     
    Drop Table in Database
    database. Understand with Example The Tutorial illustrates an example from Drop... Drop Table in Database Drop Table in Database...;   The Drop Statement in SQL Command is used to delete
     
    Menu Bar in Java
    choose in a menu bar. In this Tutorial we want to describe you how to create a Menu... Menu Bar in Java Menu Bar in Java...; A Menu Bar is a set of option that allow the user to choose from any one
     
    Open Source Forum/Bulletin Board Software written in Java

     
    Flex Drag Drop
      Flex  Drag and Drop : Drag and Drop is a process for selecting an item from a list or component and move on mouse pointer  and drop when release mouse pointer. Item are put from one position to another position
     
    Drag and Drop components from one frame to another frame
    ; Java code given below shows that how to drag and drop component (drop down list... Drag and Drop components from one frame to another frame Drag and Drop components from one frame to another frame
     
    Mysql Alter Drop
    Mysql Alter Drop Mysql Alter Drop...; Mysql Alter Drop is used to modify the table definition and delete the column from table. Understand with Example The Tutorial illustrate an example from 'Mysql
     
    Java Server Faces (JSF) Tutorial
    JSF Tutorial,JSF Tutorials,Java Server Face,Java Server Faces,Online JSF Tutorial JSF - Java Server Faces Tutorials...;  Complete Java Server Faces (JSF) Tutorial - JSF Tutorials
     
    Two way drag and drop in Flex`
      Flex Two Way Drag and Drop :- In this tutorial you can see two way drag and drop for list based controls. In this example we can set dragEnabled="true" dragMoveEnabled="true" dropEnabled="true"
     
    Ajax Dojo Tutorial
    Dojo, Ajax Dojo Tutorials, Online Dojo Tutorial, Dojo Examples Ajax Dojo Tutorial       ... Tutorials. About Dojo Tutorial In this tutorial, you will learn everything
     
    Ajax Dojo Tutorial
    Dojo, Ajax Dojo Tutorials, Online Dojo Tutorial, Dojo Examples Ajax Dojo Tutorial       ... Tutorials. About Dojo Tutorial In this tutorial, you will learn everything
     
    Flex Combo Box example
    example. This Control shows the drop-down list of data you passed as String...;   In this tutorial page you will be taught to utilize combo
     
    Menus
    Java Menus,Drop Down Menus,Java Menu Program,Menu Based Program Java... with a Menu. As a name indicates a Menu consists of Menu objects. These Menu... of a mouse. A MenuItem may be a String, checkbox, separator, menu etc
     
    Flex Component Move with the help of drag and drop
    Flex Button Drag and Drop with X and Y Co-ordinate :- In this tutorial you can  drag and drop for button with x and y co-ordinate or move one place to another in container. In this tutorial we can explain how to use Drag Manager
     
    Using Ant Build Scripts to Drop Mysql Table
    Using Ant Build Scripts to Drop Mysql Table,ant tutorial Using Ant Build Scripts to Drop Mysql Table  ...; This example illustrates how to drop table through the build.xml file by simply running
     
    Tomahawk selectManyMenu tag
    ;. This renders the menu of options where only one is visible at a time...; is that listbox can be set to any size and menu is always set to size "1"... user can select the items by scrolling the arrow icon up and down but its
     
    Flex ColorPicker Control
    control which is provide the functionality of the drop-down type swatch panel... and panel are appear and user select the color for use. In this tutorial we
     
    Choice Option (Combo) In Java
    ;  In this section, you will learn how to create Drop-Down List... the procedure of constructing a drop down list in java by using java awt. There is a program... Description: Following program uses the Choice class for creating a Drop-Down List
     
    Photoshop Tutorial : How to make a animated text.
    How to design a water drop.< How to make a animated... key) and write any text as you like. Cutout Effect: Go to Filter Menu > Artistic > Cutout and make setting. Dry Brush Effect: Go to Filter Menu >
     
    Tomahawk navigationMenuItem tag
    to provide the menu items and sub items. The label for the item is set using... by this navigation menu item. split : The split attribute expects a boolean value that, when true, indicates that this menu should be split when it is rendered
     
    Tomahawk selectOneMenu tag
    one  among the list of available options. In the menu only one option... between listbox and menu. listbox can be specified of any size but menu is set to size... language of the component when displayed. style : It is used to set the CSS
     
    Menu Shortcuts
    Menu Shortcuts,Menu Shortcuts Program Java,Menu(Hot Keys) Shortcuts Example Menu Shortcuts    ... also provides a feature of menu shortcuts and speed keys. You must be familiar
     
    The easy Slider plug-in of jQuery
    The easy Slider plug-in of jQuery  In this tutorial, we will discuss... also see left image which slide down immediately, by clicking on left arrow...;/script> <link href="css/screen.css" rel="
     
    Menus
    Java: Menus Types of menus Think of a menu as a way to arrange buttons. There are several types. Dropdown menus hang down from the menu bar..., and JMenuItem A menu bar can be added to the top of any top-level containers, eg, JFrame
     
    Creating Menu using GWT
    Creating Menu using GWT Creating Menu using GWT...;   This example describes the Basics for building the Menu using GWT. The steps involved in Building the Menu Structure are described below
     
    Rationale for GUI tutorial decisions
    Java: Rationale for GUI tutorial decisions Table of Contents Rationale for GUI tutorial decisions Java... of "GUI editors" that allow you to build your GUI with a drag-and-drop style
     
Site navigation
 

 

Send your comments, Suggestions or Queries regarding this site at roseindia_net@yahoo.com.

Copyright © 2006. All rights reserved.