Forum Moderators: open
I am creating a 'jump menu' in Dreamweaver MX 2004 and wondered if there was any way I could assign attributes to the text/list entries in the menu?
For example, items in the jump menu are divided into areas, such as
'Widgets'
Blue Widgets
Green Widgets
'Large Widgets'
X Large
XX Large
I would like to colour the Widgets entry in a 'blue' and the 'Large Widgets' in a 'red' etc.
Here's a snip of the code which is being generated:
<select name="Application Areas" class="rolldowncopy" id="Application Areas" onChange="MM_jumpMenu('parent',this,1)">
<option value="#" selected>Application Areas - Quick Links</option>
<option value="#">Application area 1:</option>
<option value="site/area1.htm"> Blue Widgets </option>
I have applied a CSS class to control the basic text size. If I were to add a colour attribute to this CSS it would presumably colour all text to this value?
Whereas I actually want to be able to assign a number of colours to each 'section' of the jump menu.
Any thoughts appreciated.
Many thanks
Mark
CSS:
.option-red {background-color: #f00;}
HTML:
<select name="Application Areas" class="rolldowncopy" id="Application Areas" onChange="MM_jumpMenu('parent',this,1)">
<option class="option-red" value="#" selected>Application Areas - Quick Links</option>
<option value="#">Application area 1:</option>
<option style="background-color: #ff0;" value="site/area1.htm"> Blue Widgets </option>