Jump to content

Recommended Posts

[!--quoteo(post=349799:date=Feb 27 2006, 06:44 AM:name=shan_cool)--][div class=\'quotetop\']QUOTE(shan_cool @ Feb 27 2006, 06:44 AM) [snapback]349799[/snapback][/div][div class=\'quotemain\'][!--quotec--]
Hi all,

I want to get a value of a text box in a same form.
how can i do it?

can anybody help me?
Thanks,
Shan
[/quote]

$_POST['text box name here'];
[!--quoteo(post=350145:date=Feb 28 2006, 12:20 AM:name=shan_cool)--][div class=\'quotetop\']QUOTE(shan_cool @ Feb 28 2006, 12:20 AM) [snapback]350145[/snapback][/div][div class=\'quotemain\'][!--quotec--]
hi,
Thanks for ur reply,It does not work.

shan
[/quote]

What are you trying to do with it? You have to press submit for PHP to get involved.

Assume the filename is "thisfile.php".
[code]
<?php
$name = $_POST['name'];
print $name;
?>
<form action="thisfile.php" method="post"><input name="name"><input type="submit"></form>
[/code]

This will print what ever you put in the field after you submit it. The page does have to reload.
This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

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.