Forgot Password / Register
Site Statistics
Total Members: 520
Total Tutorials: 242
Newsest User: 8884244477
Todays Unique Hits: 33
0 Users 2 Guests Online

Form selection redirect

This will allow you to make a form selection and on change redirect to a URL.

Add the below code to you HEAD section.
Code
<script type="text/javascript">
<!--<![CDATA[
function switchme(){
if(document.getElementById('url').value != ''){
window.location = document.getElementById('url').value;
}
}
//}}>-->
</script>


Now we can make the form. Put this in the BODY section.
Code
<select name='url' onchange='switchme()'>
<option>Select an option</option>
<option value='http://www.rmb-scripting.com'>RMB</option>
<option value='http://www.google.co.uk'>Google UK</option>
<option value='http://www.youtube.com'>YouTube</option>
</select>


Just change the options to what you want it to say and the value you want them to redirect too.
DanielXP
Author:
Views:
1732
Rating:
There are currently no comments for this tutorial.