Boston Linux & Unix (BLU) Home | Calendar | Mail Lists | List Archives | Desktop SIG | Hardware Hacking SIG
Wiki | Flickr | PicasaWeb | Video | Maps & Directions | Installfests | Keysignings
Linux Cafe | Meeting Notes | Blog | Linux Links | Bling | About BLU

BLU Discuss list archive


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Simple HTML help



Tom Metro wrote:
>
> Technically, this can't be done with just HTML. But a little bit of 
> JavaScript will accomplish what you want to do. Assigning the value of 
> the form control holding the URL to the window.location.href property 
> will cause the redirect to occur. That assignment could happen in 
> response to clicking a button. Google "window.location.href" and you 
> should turn up hundreds of examples.

You beat me to it!  I was trying to get submitting via enter to work.  
But this is how it is done with a button:

<HTML>
<HEAD>
<TITLE>Simple Redirect</TITLE>
</HEAD>
<BODY>
<FORM NAME="myform">URL:
<INPUT TYPE="text" NAME="url" VALUE="">&nbsp;
<INPUT TYPE="button" NAME="button" Value="GO" onClick="window.location = 
myform.url.value">
</FORM>
</BODY>
</HTML>




BLU is a member of BostonUserGroups
BLU is a member of BostonUserGroups
We also thank MIT for the use of their facilities.

Valid HTML 4.01! Valid CSS!



Boston Linux & Unix / webmaster@blu.org