Jump to content


Need Help... This might be a stupid question

  • Please log in to reply
1 reply to this topic

#1 redgtsviper

  • Members
  • PipPip
  • Member
  • 19 posts

Posted 24 May 2006 - 07:22 PM

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">

#2 GingerRobot

  • Staff Alumni
  • Advanced Member
  • 4,086 posts
  • LocationUK

Posted 24 May 2006 - 08:32 PM

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.

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users