Solved

opening pages using a dropdown list box

Posted on 1999-01-28
3
157 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

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

This article describes how to create custom column layout styles for Bootstrap. The article uses 5 columns to illustrate the concept, but the principle can be extended to any number of columns.
Use these top 10 tips to master the art of email signature design. Create an email signature design that will easily wow recipients, promote your brand and highlight your professionalism.
In this tutorial viewers will learn how to embed videos in a webpage using HTML5. Ensure your DOCTYPE declaration is set to HTML5: "<!DOCTYPE html>": Use the <video> tag to insert a video. Define the src as the URL of your video; this is similar to …
The viewer will learn the benefit of using external CSS files and the relationship between class and ID selectors. Create your external css file by saving it as style.css then set up your style tags: (CODE) Reference the nav tag and set your prop…

896 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

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now