View Full Version : simple html form question

05-29-2005, 08:52 PM
i am a complete newcomer to html with a simple question. could someone tell me how to do this - based on the following code....

<form name="form1" method="post" action=http://www.mysite.com/*****/wfb.php>
<input type="text" name="textfield">

how do i have the outcome of this text input form be inserted into the gap where the asterisks are? basically what i am trying to do is when you type in the text box and hit enter, you should be redirected to a URL with what you just typed included in its makeup.

many thanks for any help!

Coastal Web
05-29-2005, 10:14 PM
Many ways you could accomplish this (all of which you'd need to jump from HTML to another language...)

lets go with a simple javascript example that would work when hosted nearly anywhere. here's how it'd look:
(this has been tested, and works)

<script language="JavaScript">

function getMyPage(){
myArea = document.myForm.textfield.value;


<form name="myForm" action="javascript:getMyPage();">
<input type="text" name="textfield" size="15">
<input type="submit" value="Go!" name="submit">


Post back any questions or problems you have.
Samantha Gram

05-29-2005, 10:29 PM
hello samantha

thanks a million for the quick reply and solution. im pleased to say it works like a charm and the system is up and running now!

thanks again

Coastal Web
05-29-2005, 10:57 PM
dont mention it :)

Samantha Gram