Jump to content


This topic is now archived and is closed to further replies.


Need Help... This might be a stupid question

Recommended Posts

Is there a way I can have a single form field on a page and when I enter something into it and click submit, have the info added into my URL.

Here is may sampe code. I am sure that I am going about this all wrong

<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">

<form name="form1" method="post" action="../folder/$idNo">
<input name="idNo" type="text" id="idNo">
<input type="submit" name="Submit" value="Submit">

Share this post

Link to post
Share on other sites
So you want to submit the form and then have the values in the URL?
You need to use the GET method....

<form action="formpage.php" method="get">
<input name = "idNo" type="text">
<input type="submit" name="Submit" value="Submit">

This would give a url of www.example.com/formpage.php?idNo=the value in the field.

Share this post

Link to post
Share on other sites


Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.