how to create link in my drop down list?

Discussion in 'HTML & Website Design' started by nazmuls4, May 28, 2012.

  1. #1
    this is my coding....
    i don't know how can create link in my drop down list coding

    ===============================

    <html>
    <head>
    <title> Drop down list<title>
    </head>
    <body>

    <select name="color"><option value="bl">Black</option><option value="wh">White</option><option selected="selected" value="mr">Maroon</option></select></body>
    </html>

    please help me.....:p
     
    nazmuls4, May 28, 2012 IP
  2. robaid

    robaid Member

    Messages:
    126
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    35
    #2
    <select name="color" onChange="location.href=this.options[this.selectedIndex].value;">
    <option>Choose a color...</option>
    <option value="URL1">Color1</option>
    <option value="URL2">Color2</option>
    <option value="URL3">Color3</option>
    </select>
     
    robaid, May 28, 2012 IP