Solved

opening pages using a dropdown list box

Posted on 1999-01-28
3
174 Views
Last Modified: 2011-10-03
how do i open a page using a listbox?
0
Comment
Question by:_nin_
  • 2
3 Comments
 
LVL 4

Expert Comment

by:martinag
ID: 1845794
<FORM>
<SELECT onChange="location.href=this.options[this.selectedIndex].value">
<OPTION VALUE="page1.htm">Page 1
<OPTION VALUE="http://www.ibm.com">IBM
etc
</SELECT>
</FORM>

Martin
0
 
LVL 4

Accepted Solution

by:
ruperts earned 30 total points
ID: 1845795
This will open a page in the frame called mainwin

To see an example go to www.rest.demon.co.uk/fruit

If you want to learn about it go to...
http://www.builder.com/Programming/Kahn/120397/index.html

Rupert

<head>
<SCRIPT language="JavaScript">
function spawnWin(options) {
 var url = options[
  options.selectedIndex
  ].value+'.html';
 var winArgs = "top=10,left=10,";
 winArgs+= "width=300,height=100";
 var howdy = open(url,"mainwin");
 }
</SCRIPT>
</head>
<body bgcolor="#FFFFFF" text="#003366">

<table width="100%">
  <tr BGCOLOR="#003366" width="100%">
    <td width="100%"><p align="center"><strong><font COLOR="#ffcc00">Menu</font></strong></td>
  </tr>
  <tr BGCOLOR="#00FFFF">
    <td bgcolor="#FFcc00"><br>
    <strong><font color="#003366">Go to...</font> </strong>
      <form NAME="MachineForm">
      <p><SELECT name="salut8n" onChange="spawnWin(this.options)"
 onBlur="return options[0].selected = true">
 <option VALUE="main">Machine Guides </option>
        <option VALUE="andycapp">Andy Capp</option>
        <option VALUE="apollo9">Apollo 9</option>
       </select> </p>
    </form>
0
 
LVL 4

Expert Comment

by:ruperts
ID: 1845796
You can remove all the table tags..

i.e <table> <td> <tr> etc...

0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
jQuery Sticky Menu 24 36
Asp in script 6 39
Extracting content from meta tag PHP MYHTML DOM 3 21
output of netstat -r in Powersshell HTML 3 28
Not sure what the best email signature size is? Are you worried about email signature image size? Follow this best practice guide.
Today, the web development industry is booming, and many people consider it to be their vocation. The question you may be asking yourself is – how do I become a web developer?
In this tutorial viewers will learn how add a scalable full-width header using CSS3. Create a new HTML document with an internal stylesheet. Set a tiled background.:  Create a new div and name it Header. Position it with position:absolute at the top…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)

828 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question