Results 1 to 3 of 3

Thread: <SELECT> problem

  1. #1

    Thread Starter
    Member
    Join Date
    Mar 2000
    Posts
    56

    <SELECT> problem

    using the select (drop down list), what code would i need to do to put the items :

    Alaska,
    UK,

    and then when one of these is selected it should take the user to a webpage relating to that selection.

    E.G. Alaska - www.alaska.com
    UK - www.uk.com

    Any help would be great.

    Cheers
    Nick

  2. #2
    Frenzied Member Rick Bull's Avatar
    Join Date
    Apr 2002
    Location
    England
    Posts
    1,444
    Well with JavaScript you can do it like this:

    Code:
    <select onchange="document.location.href = this.options[this.selectedIndex].value">
      <option value="http://www.alaska.com/">Alaska</option>
      <option value="http://www.uk.com/">UK</option>
    </select>
    But if you have PHP, Perl or any other server-side method I would really recommend using them as about 10%-15% of the Internet do not have Javascript turned on in their browsers. If you have one let us know and we can give you the appropriate code.

  3. #3

    Thread Starter
    Member
    Join Date
    Mar 2000
    Posts
    56
    thankyou kindly.
    That was the exact expert knowledge i was after.

    Cheerz.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width