Code Newbie
News     Forums     Search     Members     Sign Up    

My Code Newbie
Username

Password

Articles/Snippets
ASP Classic
ASP.NET
C
C#
C++
HTML / CSS
Java
Javascript
Linux / BSD
Perl
PHP
Python
Ruby
SQL
VB 6
VB.NET

C.N. Friends
  Planet Rome

Link to Us!
Code Newbie
  Code Newbie
    forums
Old 11-10-2004, 01:17 PM   #1 (permalink)
buchannon
Registered User
 
buchannon's Avatar
 
Join Date: Nov 2004
Posts: 43
buchannon is on a distinguished road
Redirecting with a form

I am trying to put a dropdown menu to let the user select where they want to go, and then click on the button to go there. I think I know why this isn't working, but I can't figure out how to do it.

Quote:
<html><head><body>
<%
dim unclink
unclink=request.querystring("unclink")
%>
<form mehtod="get" action=" <% response.write(unclink) %>" class="menu">
<select title="UNC Directory" name="unclink" id="unclink" style="width:150px" class="layoutMenu">

<option value="http://www.unco.edu/dss/uncdirectory3.asp" selected> -UNC LINKS-</potion>
<option value="http://www.unco.edu/" >UNC HOME</option>
-->
</select>
<input type="submit" value="Submit">
buchannon is offline   Reply With Quote
Old 11-10-2004, 01:50 PM   #2 (permalink)
rdove
Masked Moderator
 
rdove's Avatar
 
Join Date: May 2002
Location: Indianapolis, IN
Posts: 260
rdove is on a distinguished road
method is spelled wrong in your code
__________________
~Ryan

rdove is offline   Reply With Quote
Old 11-10-2004, 05:04 PM   #3 (permalink)
buchannon
Registered User
 
buchannon's Avatar
 
Join Date: Nov 2004
Posts: 43
buchannon is on a distinguished road
That code is just an idea I had, it won't work even when fully functional... How can I redirect a user from a drop down menu? For instance, http://webmonkey.wired.com/webmonkey.../builders.html does it.
buchannon is offline   Reply With Quote
Old 11-11-2004, 08:32 AM   #4 (permalink)
buchannon
Registered User
 
buchannon's Avatar
 
Join Date: Nov 2004
Posts: 43
buchannon is on a distinguished road
wow that was a lot easier than I thought it would be:

html file:
Quote:
<form method="post" action="redirect.asp" class="menu">
<select title="UNC Directory" name="unclink" id="unclink" style="width:150px" class="layoutMenu">

<option value="" selected> -UNC LINKS-</option>
<option value="http://www.unco.edu/" >UNC HOME</option>
-->
</select>
<input type="submit" value="Submit">
</form>
then the redirect.asp file:
Quote:
<%
dim unclink
unclink=request.form("unclink")
if unclink="" then unclink="http://www.unco.edu/"
response.redirect unclink
%>
buchannon is offline   Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
HTML form preview then INSERT using PHP & MySQL SteveSoler PHP 16 09-21-2008 11:59 PM
EMERGENCY: Dynamic form processing DavH27 PHP 8 10-27-2004 07:52 PM
javascript riddle: why won't my form submit from this text link? sde HTML, XML, Javascript, AJAX 6 09-29-2004 05:56 AM
breaking down an array from a form metazai PHP 12 07-09-2004 06:18 AM
Passing form data to PHP with Javascript bdl PHP 5 07-03-2002 10:18 AM


All times are GMT -8. The time now is 08:39 PM.


Powered by vBulletin® Version 3.7.0
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.0.0 RC8





Copyright © 2000-2008, Milano Interactive
Web Hosting provided by Portal 360 Web Hosting