Jump to content

_$POST ?????


PhdJB

Recommended Posts

That is just a matter of reading up on basic PHP and MySQL...

 

The form:

<form action="script.php" method="post">
  <input type="text" name="fullname">
  <input type="text" name="phone">
  <input type="submit value="Submit">
</form>

 

 

script.php: (part of it)

<?PHP
$fullname = $_POST['fullname'];
$phone = $_POST['phone'];
?>

 

Thats all it takes to get the your "stuff" from your forms "connected" to your PHP code. Now you can do what ever you want with the information by using $fullname and $phone. You could for instance write them to a database like MySQL...

 

 

Link to comment
https://forums.phpfreaks.com/topic/55266-_post/#findComment-273158
Share on other sites

in your php

 

heres what your form looks like:

 

<form name="thisform" method="post" action="process.php">
Username:   <input type="text" name="txName" /><br />
Password:   <input type="password" name="txPass" /><br />
<input type="submit" name="submit" value="Login" /></form>

and your process.php is like this

 

$name = $_POST['txName'];
$pass = $_POST['txPass'];

//then you do the rest

Link to comment
https://forums.phpfreaks.com/topic/55266-_post/#findComment-273159
Share on other sites

Archived

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

×
×
  • 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.