HTML - Not Possible To Have Multiple Choice Drop-down Menu In Html?
Hi!
I would like to create a drop down menu in HTML where the user can choose many options, not possible in simple HTML? Dharma Similar TutorialsWhen designing a webpage is there a way to see the correct multiple choice answer using firebug or some like extension. I have a small problem with my 'form drop down menu'. I've got a content box made of cells. There is the title box and the content box. In the header, i'd like to place on the left site the content's title and on the right side, i would like to have a drop down menu. So far, so good. The problem appears as soon as I add the <form> tag to my dropdown menu. The problem is that it pulls the cell in height and I cannot modify it with my HTML-editor. Can any one tell me what i can do, or even better, post me the finished code Here is my code: HTML Code: <body> <table width="630" border="0" cellspacing="0" cellpadding="0"> <tr> <td width="630" height="10" align="center" bgcolor="#4D4D4D"> <table width="620" border="0" cellspacing="0" cellpadding="0" id="table4"> <tr> <td class="tabletitle"> <span lang="en-us">Titel</span></td> <td class="tabletitle" width="171"><p align="right"> <form ACTION="URI"> <p align="right"> <select name=selection onchange="location.href=(form.selection.options[form.selection.selectedIndex].value)"> <option class="under" selected value="In this section">In this section:</option> <option> </option> <option value="http://url"> URL 1</option> <option value="http://url"> URL 2</option> <option value="http://url"> URL 3</option> </select></p> </form> </td> </tr> </table> </td> </tr> </table> </body> Thank you in advance Hello everyone, im very sorry if i am reposting this question, i have tried to find the answer on the forum with no luck. I am very new to HTML and am learning everyday, i am trying to make a top menu kinda like on www.quantas.com.au. i would just like the drop down to be horizontal instead of the normail vertical menu. If anyone has any code to help me out or a tutorial that i would be able to learn from, i would be very appreciative. Thankyou in advance. Mikey i want to make a thin drop down menu. like rather then being 20pxls high i want it be be 10-15pxls high and i want the background color to be black and the text to be white. just something simple and customizeable is perfect Hi, I have a website built in HTML and CSS in DW CS4. I have a horizontal top navigational menu and wish to add a drop down menu. When I select the entire menu and click on properties I can add a vertical menu item, but it is not an actual drop down. when I copy the html from another site that does have a functioning drop down, it does not work. So this is what it looks like: <div id="runner"> <ul id="MenuBar1" class="MenuBarHorizontal"> <li><a href="page1.html">page 1</a></li> <li><a href="page2.html">page 2</a></li> what shoudl the code look like to add a drop down menu to each of these pages? Or should I do something in my spry menu? Can anyone help me with this? I've been trying to figure out how to create a drop down menu in place of the original navigation on my website. I found what I want to do I just need to know how to apply it. Here's the website with what I want to do: http://www.dynamicdrive.com/dynamici...roptabmenu.htm It's example 2. Code: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <title>|*|Doll Directory|*|</title> <meta http-equiv="content-type" content="text/html; charset=utf-8" /> <!-- Stylesheet --> <style type="text/css"> body { background: url(''); background-color: #FFFFFF; font-family: "Trebuchet MS"; font-size: 12px; line-height: 1.5em; color: #ffffff; letter-spacing: 1px; } #container { margin: 0 auto; border: 4px solid #FF0080; width: 722px; background-color: #FFFFFF; } #header { width: 722px; } #content { background-color: #FFFFFF; padding: 4px; width: 500px; text-align: left; margin-left: 0px; margin-top: -8px; } #sidebar { float: right; width: 212px; background-color: #FFFFFF; margin-right: 0px; margin-top: -8px; height: auto; padding: 4px; text-align: center; } #footer { clear: both; background-color: #FF0080; margin: 0px; width: 722px; height: 45px; text-align: center; } #bar { text-align: center; margin: 8px; padding: 12px; margin-left: 0px; background-color: #FF0080; margin-top: 0px; width: 700px; } a.nav:link, a.nav:visited, a.nav:active { text-decoration : none; font-family : Trebuchet MS; font-size : 10px; line-height : 12pt; text-align : center; color : #fa829a; font-weight : bold; background-color : #252525; cursor : default; text-transform : uppercase; padding : 5px; border-right : 5px solid #c15876; border-bottom : 1px dotted #7d7d7d; } a.nav:hover { color : #ffffff; background-color : #363636; border-right : 5px solid #d58fb4; border-bottom : 1px dotted #515151; } .site { font-family: Gabriola; font-size: 22px; font-weight: bold; color: #fa829a; } h1 { margin-top: 5px; text-align: left; color: #fa829a; font-family: Gabriola; font-size: 25px; font-weight: bold; padding: 5px; font-style: none; border-bottom: 1px dotted #535152; letter-spacing: 1px; } h1:first-letter { text-align: left; color: #fa829a; font-size: 25px; font-style: normal; font-weight: normal; } h2 { font-weight: bold; text-align: left; color: #fa829a; font-family: Gabriola; font-size: 18px; border-bottom: 1px dotted #8a8988; padding-bottom: 2px; margin-top: 7px; margin-bottom: 7px; } a:link,a:visited,a:active { text-decoration: none; font-family: Trebuchet MS; cursor: default; font-size: 11px; color: #fa829a; font-weight: normal; } a:hover { font-family: Trebuchet MS; font-size: 11px; text-decoration: none; color: #fa829a; background-color: white; padding: 1px; } b,strong { font-family: "Trebuchet MS"; font-size: 11px; font-weight: bold; color: #fa829a; } i,em { font-family: Gabriola; font-style: italic; font-size: 11px; color: #fa829a; } u { font-family: Gabriola; font-size: 11px; border-bottom: 1px dotted #add568; color: #fa829a; padding-bottom: 1px; text-decoration: none; } blockquote { width: 350px; margin: 8px; padding: 3px; background: #fff; border: 3px solid #413b31; cursor: default; color: #fa829a; } </style> </head> <body> <div id="container"> <!-- Header image --> <div id="header"> <img src="http://missdolldecade.awardspace.us/MDD_Banner.png" border="0" alt="" /> <div id="bar"> <div class="nav"><a href="http://missdolldecade.awardspace.us/index.html" class="nav"><font color="#FFFFFF">Home</font></a> <a href="http://missdolldecade.awardspace.us/rules.html" class="nav"><font color="#FFFFFF">Home</font></a> <a href="http://missdolldecade.awardspace.us/scores.html" class="nav"><font color="#FFFFFF">Home</font></a> <a href="http://missdolldecade.awardspace.us/round1.html" class="nav"><font color="#FFFFFF">Home</font></a> <a href="http://missdolldecade.awardspace.us/round2.html" class="nav"><font color="#FFFFFF">Home</font></a> <a href="http://missdolldecade.awardspace.us/round3.html" class="nav"><font color="#FFFFFF">Home</font></a> <a href="http://missdolldecade.awardspace.us/awards.html" class="nav"><font color="#FFFFFF">Home</font></a> <a href="http://missdolldecade.awardspace.us/judges.html" class="nav"><font color="#FFFFFF">Home</font></a> <a href="http://missdolldecade.awardspace.us/enter.html" class="nav"><font color="#FFFFFF">Home</font></a> <a href="http://missdolldecade.awardspace.us/links.html" class="nav"><font color="#FFFFFF">Home</font></a></div> </div> <!-- Sidebar --> <div id="sidebar"> <h2>Tagboard</h2> <!-- Begin ShoutMix - http://www.shoutmix.com --> <iframe title="missdolldecade" src="http://www6.shoutmix.com/?missdolldecade" width="207" height="400" frameborder="0" scrolling="auto"> <a href="http://www6.shoutmix.com/?missdolldecade">View shoutbox</a> </iframe> <br /><a href="http://www.shoutmix.com" title="Get your own free shoutbox chat widget at ShoutMix!">ShoutMix chat widget</a><br /> <!-- End ShoutMix --> </div> <!-- Main content --> <div id="content"> <h1>Updates</h1> </div> <!-- Footer --> <div id="footer"> <a href="http://missdolldecade.awardspace.us">Miss Doll Decade</a> (C) Amber Riley 2010<br> <a href="http://missdolldecade.awardspace.us/contact.html">Contact MDD</a> </div> <!-- Container End --> </div> </div> </body> </html> Hi! I hope you guys can help with what is wrong here. Ive been slaving over this html trying to get it to work and I gave up. Heres my problem. I have two drop down menus on this page. However the right drop down menu only goes to a page from the menu on the left. I have them separated, Brazil and Romania, so the Romania menu links pull up one of the Brazil pages and I dont understand why because in the html I have clearly specified the links to go to different pages. I will attach the html used and ask someone to please point out the source of this html conflict. Hi Peeps, I have created a table of 24 football teams with links to all their forums so other people can link up with fans from around the country and talk football. However I realise that some of these teams have upto four forums. I would like to keep the table as it is and create some kind of drop down where the names of the forum drop down. Is it possible to create some sort of drop down in a table and can someone point me in the right direction so I might create one. Here is the page: http://www.freewebs.com/jonnibravo/l...forumsmain.htm Hello, I am a newbie to html but am working on a company website. I am looking for help with the drop down nav bar. I want to have the bar justified underneath the part that you are hovering over (for example, when you hover over Douglas Cardinal, the words biography, philosophy, etc would be justified underneath. When you click portfolio, current projects, museums, etc would be justified under portfolio) http://www.djcarchitect.com/portfoli...tprojects.html Is this possible? Thanks!! I have created a custom html dropdown menu for my site. The thing is it looks perfect in Firefox 5.0 (for me it does anyway) and works just as expected but in other browsers such as Opera 10.60, Chrome 5.0.375.125, it doesn't work properly. and it works semi ok in IE 8. For example if I hover over one of the menu buttons in opera or chrome there is meant to be a drop down box, this doesn't show in Opera or chrome but does in IE? You can view the menu on my test site - http://www.themidwiferysanctuary.com/testsite/ There is more to the menu, you can use the following log in - Username: Jade Password 130489 Does anyone have any thoughts on how to get the dropdown compatiable with all (or most) browsers? I would post the code but it won't let me even when using the code tags.......... If you want to see the javascript code then please just let me know. Im not sure any of the above makes sense?? Thank you, Jade Please help. This is what I have so far http://bartletagency.com/m/x2.php Now, obviously with business cards there many different options. I need something to calculate on the side the total after picking each drop box option, or if easier, after hitting "calculate total." (preferably with the numbers in a table so I can make it appear by itself right underwear the send button) . Example: 1000 business cards in blue, say, would need to come up at 50 dollars if they pick 3-1, but if they pick 3-22 it needs to come up 60 dollars if they pick the other color, green, and pick 3-1, the label would need to turn to $55.00, if they pick 3-2 with the color green the label would need to say $65.00 how can i do this please? here is the code I have which made up the PHP file i linked you to above. code: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd"> <html> <head> <title>Lesson 3</title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> </head> <body> <?php if ($_SERVER['REQUEST_METHOD'] != 'POST'){ $me = $_SERVER['PHP_SELF']; ?> <h1 align="center">Business Cards</h1> <form name="form1" method="post" action="<?=$me?>"> <table border="0" align="center" cellpadding="5" cellspacing="0"> <tr> <td align="right" valign="middle">Quantity:</td> <td><select name="Quantity: "> <option value="1000">1000</option> <option value="2500">2500</option> <option value="5000">5000</option> <option value="10,000">10,000</option> </select> </td> </tr> <tr> <td align="right" valign="middle">color</td> <td><select name="color"> <option value="blue">blue</option> <option value="green">green</option> </select> </td> </tr> <tr> <td align="right" valign="middle">3</td> <td><select name="3"> <option value="small">3-1</option> <option value="medium">3-2</option> </select> </td> </tr> <tr> <td> </td> <td><input type="submit" name="Submit" value="Send"> </td> </tr> </table> </form> <?php } else { error_reporting(0); // initialize a array to //hold any errors we encounter $errors = array(); // test to see if the form was actually // posted from our form $page = $_SERVER['HTTP_HOST'].$_SERVER['PHP_SELF']; if (!ereg($page, $_SERVER['HTTP_REFERER'])) $errors[] = "Invalid referer<br>\n"; // check to see if a name was entered if (count($errors)>0) { foreach($errors as $err) echo "$err<br>\n"; echo "<br>Please use your browser's Back button to fix."; } else { // no errors, so we build our message switch($_POST['color']){ case 'red': $recipient = 'mathew420@gmail.com'; break; case 'green': $recipient = 'mathew420@gmail.com'; break; case 'blue': $recipient = 'mathew420@gmail.com'; break; default: $recipient = 'mathew420@gmail.com'; } $subject = "Widget On Line Order"; $from = stripslashes($_POST['Name']); $msg = "Message sent by $from\n"; $msg.="\nSize: ".$_POST['size']; $options=$_POST['options']; $msg.="\nOptions:"; if ($options) for ($i=0;$i<count($options);$i++) $msg.= "\n- $options[$i]"; else $msg.="\n- None"; $msg.="\nColor: ".$_POST['color']; $extension=($_POST['extension'])?"Extension: Yes":"Extension: No"; $wallmount=($_POST['wallmount'])?"Wallmount: Yes":"Wallmount: No"; $deskmount=($_POST['deskmount'])?"Deskmount: Yes":"Deskmount: No"; $msg.="\n$extension\n$wallmount\n$deskmount"; $msg.="\n".stripslashes($_POST['MsgBody'])."\n"; if (mail($recipient,$subject,$msg)){ echo "<p>Thanks for your order!</p>"; echo nl2br($msg); } else echo "An unknown error occurred."; } } ?> </body> </html> thanks so much Hello all! I want to have a page with multiple drop-down menus. The user will select for example "type of car" and a drop-down menu of 3-4 colors will appear... And then, if the user selects one of these colors, another drop-down menu will appear with the available brands of cars for the respective colour... Can you give me hints on how to start? Hi there I checked through a bunch of this forum but I can't find anything on this topic. If it's already been addressed, I'd be thankful if you could point me to the thread. If not, this is my problem.... I need to have 2 drop down menus in the same form, so that when the user clicks submit (OK in this case) both selected fields are posted.... Code: <form method="post" action="show.html"> <table> <tr> <td>Select a color</td> <td><select name=color"> <option value="red">red</option> <option value="green">green</option> <option value="yellow">yellow</option> <option value="orange">orange</option> <option value="purple">purple</option> <option value="blue">blue</option> </select> </td> </tr> <tr> <td>Select a shape</td> <td><select name=shape"> <option value="circle">circle</option> <option value="square">square</option> <option value="triangle">triangle</option> <option value="hexagon">hexagon</option> </select> </td> </tr> <tr> <td><input type="submit" value=" OK "></td> </tr> </table> </form> This code displays the drop downs perfectly but only the color is being posted to show.html It's something small but I can't figure this one out. I'm not sure if you can even have 2 drop downs with 1 submit button. Any and all assistance is greatly appreciated! Perkie Hi All, I'm trying to create an information page with HTML whereby people can find an address of a store based on the conditional dropdown boxes selected. Based on the choices selected, it would display the results. E.g. Dropdown 1: Select State Dropdown 2: Select Retail Store Output: Address of the retail store (displayed on the same page) I came across a solution in one of the threads for making multiple conditional dropdowns for a form. The code given works extremely well but I'm not sure how to have a text output result on the same page. Can anyone help? Thanks a bunch in advance! HTML Code: <script type="text/javascript"> // Place in this array the ID of the element you want to hide var hide=['the_minutemen','Planet_Smashers','crass','Madonna', 'the_misfits','next','id2']; function setOpt() { resetOpt(); // Call the resetOpt function. Hide some elements in the "hide" array. for(var i=0,sel=document.getElementsByTagName('select');i<sel.length;i++) { sel[i].onchange=function() { if(this.parentNode.tagName.toLowerCase()!='div') resetOpt(); // Hides the elements in "hide" array when the first select element is choosen try { document.getElementById(this.value).style.display=''; } catch(e){} ; // When the value of the element is not an element ID } } } window.addEventListener?window.addEventListener('load',setOpt,false): window.attachEvent('onload',setOpt); function resetOpt() { for(var i=0;i<hide.length;i++) document.getElementById(hide[i]).style.display='none'; // Hide the elements in "hide" array } </script> Artist: <select> <option value="the_minutemen">The Minutemen</option> <option value="Planet_Smashers">Planet Smashers</option> <option value="crass">Crass</option> <option value="Madonna">Madonna</option> <option value="the_misfits">The Misfits</option> </select> <div id="the_minutemen"> The Minutemen Album: <select> <option value="album">The Minutemen album1</option> <option value="next">Show next 'select' element</option> <option value="album">The Minutemen album3</option> <option value="album">The Minutemen album4</option> <option value="album">The Minutemen album5</option> </select> </div> <div id="Planet_Smashers"> Planet Smashers Album: <select> <option value="album">The Planet Smashers album1</option> <option value="id2">Show element with the id of 'id2'</option> <option value="album">The Planet Smashers album3</option> <option value="album">The Planet Smashers album4</option> <option value="album">The Planet Smashers album5</option> </select> </div> <div id="crass"> Crass Album: <select> <option value="album">Crass Album1</option> <option value="next">Show next 'select' element</option> <option value="album">Crass Album3</option> <option value="album">Crass Album4</option> <option value="album">Crass Album5</option> </select> </div> <div id="Madonna"> Madonna Album: <select> <option value="album">madonna Album1</option> <option value="id2">Show element with the id of 'id2'</option> <option value="album">madonna Album3</option> <option value="album">madonna Album4</option> <option value="album">madonna Album5</option> </select> </div> <div id="the_misfits"> The Misfits Album: <select> <option value="album">the_misfits Album1</option> <option value="album">the_misfits Album2</option> <option value="album">the_misfits Album3</option> <option value="id2">Show element with the id of 'id2'</option> <option value="album">the_misfits Album5</option> </select> </div> <div id="id2"> Element with an ID of "id2" <select> <option>Opt1</option> <option>Opt2</option> <option>Opt3</option> </select> </div> <div id="next"> "Next" element <select> <option>Opt1</option> <option>Opt2</option> <option>Opt3</option> </select> </div> Okay here is the previous thread that lead me to this issue. http://www.htmlforums.com/html-xhtml...tml#post670803 It solved my issues of opening a new window based off of the selection in a drop down, how ever I have 13 drop downs and the script from the above thread only allows one drop down to work. The drop downs will increase, is there any way to get them all to work. Thanks dt_gry I have a drop down menu on my page, and I want to change the background color of the box from white to match the rest of the page, how do I do this. Thanks Code: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <meta name="language" content="english"> <meta http-equiv="Content-Style-Type" content="text/css"> <title>Welcome to my Home Page</title> <script language="JavaScript" type="text/javascript"> ////The source for this script came from http://allwebco-templates.com/support/S_menus_dropdown.htm//// ///For the Game,I changed the back ground picture. I realize it's not JS/// <!-- function land(ref, target) { lowtarget=target.toLowerCase(); if (lowtarget=="_self") {window.location=loc;} else {if (lowtarget=="_top") {top.location=loc;} else {if (lowtarget=="_blank") {window.open(loc);} else {if (lowtarget=="_parent") {parent.location=loc;} else {parent.frames[target].location=loc;}; }}} } function jump(menu) { ref=menu.choice.options[menu.choice.selectedIndex].value; splitc=ref.lastIndexOf("*"); target=""; if (splitc!=-1) {loc=ref.substring(0,splitc); target=ref.substring(splitc+1,1000);} else {loc=ref; target="_self";}; if (ref != "") {land(loc,target);} } //--> <!-- /// The JS below is for the date and time. and i got the sorce from http://www.re-es.org/ /// var day_names = new Array(7) day_names[0] = "Sunday" day_names[1] = "Monday" day_names[2] = "Tuesday" day_names[3] = "Wednesday" day_names[4] = "Thursday" day_names[5] = "Friday" day_names[6] = "Saturday" var month_names = new Array(12) month_names[0] = "January" month_names[1] = "February" month_names[2] = "March" month_names[3] = "April" month_names[4] = "May" month_names[5] = "June" month_names[6] = "July" month_names[7] = "August" month_names[8] = "September" month_names[9] = "October" month_names[10] = "November" month_names[11] = "December" date_now = new Date() day_value = date_now.getDay() date_text = day_names[day_value] month_value = date_now.getMonth() date_text += " " + month_names[month_value] date_text += " " + date_now.getDate() date_text += ", " + date_now.getFullYear() minute_value = date_now.getMinutes() if (minute_value < 10) { minute_value = "0" + minute_value } hour_value = date_now.getHours() if (hour_value == 0) { greeting = "Good Morning " time_text = " at " + (hour_value + 12) + ":" + minute_value + " AM" } else if (hour_value < 12) { greeting = "Good Morning " time_text = " at " + hour_value + ":" + minute_value + " AM" } else if (hour_value == 12) { greeting = "Good Afternoon " time_text = " at " + hour_value + ":" + minute_value + " PM" } else if (hour_value < 17) { greeting = "Good Afternoon " time_text = " at " + (hour_value - 12) + ":" + minute_value + " PM" } else { greeting = "Good Evening" time_text = " at " + (hour_value - 12) + ":" + minute_value + " PM" } document.write(greeting + " Today is " + date_text + time_text) //--> </script> <link rel="stylesheet" type="text/css" href="css/main.css"> </head> <body> <div id="container"> <p><img id="banner" src="images/banner.gif" alt="banner"></p><hr color="#FF0000"></p> <ul id="nav"> <li><form action="#" method="post"> <select name="choice" size="1" onChange="jump(this.form)" class="dropdown"> <option value="index.html" selected>Home</option> <option value="scripts_developed.html">Scripts Developed</option> <option value="best_practices.html">Best practices for JavaScript coding</option> <option value="ajax.html">AJAX</option> <option value="JavaScript_frustrations.html">JavaScript frustrations & Javascript Game</option> </select> </form> </li> </ul> <div id="content"></div> </div> <table width="1050" border="0" align="center"> <tr> <td align="center"><p><img src="images/logo1.gif" width="300" height="300" hspace="30"><img src="images/logo3.gif" width="300" height="300"><img src="images/logo2.gif" width="300" height="300"></p> <p><img src="images/logo4.gif" width="300" height="300" hspace="30"><img src="images/logo5.gif" width="300" height="300"><img src="images/logo6.gif" width="300" height="300"></p></td> </tr> </table> <p> </p> <p> </p> </body> </html> Hello All, I am new to coding and looking to self teach myself with the help of this forum so I can design my own web site. I am looking for the best solution for searching a database. The database will for example contain USA States and Cities with the final result being an item or thing etc. that the search criteria points to. Let's say for example I want to know where all the Dentists are in the State of Maryland. I found this example below and It creates the option to choose a state however how do you make it accept your choice once chosen and go to the next webpage for the next lookup or whatever you decide to have it do next. I guess what I am asking is how do you make a Search or Go button take you to your drop down search criteria. <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <html><head> <meta http-equiv="Content-Type" content="text/html; charset=unicode"> <meta content="MSHTML 6.00.2900.3429" name="GENERATOR"></head> <body><select name="state" size="1"> <option value="NA" selected="">Select A State</option> <option value="Blank">--------------------</option> <option value="AL">Alabama</option> <option value="AK">Alaska</option> <option value="AZ">Arizona</option> <option value="AR">Arkansas</option> <option value="CA">California</option> </select> </body></html> Thanks for any assistance... I am sure there is a simple answer to this Dear HTML Experts, I need your help, I would love to have a dropdown menu. Which drop out of a image? Like when your mouse is at the image, the menu shows up vertically? Thanks Good day guys... is there anyone who can share about drop down menu's Hey guys, I am very new to web design, however have some basic knowledge of html. I am designing a simple site which needs a drop down menu tab for only ONE TAB in the nav bar. See the following site for an example: http://www.dynamicdrive.com/dynamici...wntabsdemo.htm Again I need a drop down menu for only one tab. How do I achieve this? |