How can I show a category name in html dropdown list?

usmovie

New Member
I have a dropdown list in a form. There are many items. I want to show the category names in the dropdown list which the users will be able to see but wont be able to select. So far I have this. But obviously it is not working. Any help would be appreciated. Thanks in advance.\[code\]<select id="item_name" name="item_name"> <dl> <dt>Category 1</dt> <dd><option value="http://stackoverflow.com/questions/15710540/1">Item 1</option></dd> <dd><option value="http://stackoverflow.com/questions/15710540/2">Item 2</option></dd> <dd><option value="http://stackoverflow.com/questions/15710540/3">Item 3</option></dd> <dt>Category 2</dt> <dd><option value="http://stackoverflow.com/questions/15710540/4">Item 4</option></dd> <dd><option value="http://stackoverflow.com/questions/15710540/5">Item 5</option></dd> <dd><option value="http://stackoverflow.com/questions/15710540/6">Item 6</option></dd> </dl> </select>\[/code\]
 
Back
Top