•
•
•
•
What is DaniWeb IT Discussion Community?
You're currently browsing the JavaScript / DHTML / AJAX section within the Web Development category of DaniWeb, a massive community of 374,176 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 3,439 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our JavaScript / DHTML / AJAX advertiser: Lunarpages Web Hosting
Views: 2134 | Replies: 1
![]() |
| |
•
•
Join Date: Jan 2005
Posts: 9
Reputation:
Rep Power: 0
Solved Threads: 1
I want to us a simple HTML drop down lists (<select name="menu"....) as a quick jump between a couple of different html pages. I was able to come up with the script to have the pages jump to the URLs. However, I was hoping to have the current page dynmically selected. For example, If I am on the page for Nike Running Shoes (nike-running-shoes.html) that value in the drop down would be selected.
Any suggestions...?
Any suggestions...?
here is the script:
html Syntax (Toggle Plain Text)
<select id="jump"> <option value="http://localhost/page2.html" onclick="javascript:window.location = this.value;">page2</option> <option value="http://localhost/page1.html" onclick="javascript:window.location = this.value;">page1</option> <option value="http://localhost/page3.html" onclick="javascript:window.location = this.value;">page3</option> </select> <script type="text/javascript"> var slect=document.getElementById('jump'); if(slect.value!==location.href){ slect.value = location.href; } </script>
toast
![]() |
•
•
•
•
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
•
•
•
•
•
•
•
•
DaniWeb JavaScript / DHTML / AJAX Marketplace
Similar Threads
- php drop down menu to search multiple sql tables (PHP)
- I NEED HELP PLEASE:Warning: mysql_num_rows(): (PHP)
- I NEED HELP PLEASE:Warning: mysql_num_rows(): (MySQL)
- Warning: mysql_num_rows(): (PHP)
Other Threads in the JavaScript / DHTML / AJAX Forum
- Previous Thread: Javascript Compiler/Checker?
- Next Thread: Easy w Frames tough w CSS


Hybrid Mode