Tuesday, July 20, 2010
KNOW ABOUT POST
After you learn about HTML, you will know that HTML has method “POST” to send information for from PAGE into another page.
For example:
Previous.php
<html><body>
<form action="next.php" method="post">
<input type="text" name="var" size="25"/>
<input type="submit" value="Submit">
</form>
</body></html>
In other page (next.php) you can get the value of variable that declared in previous page.
Next.php
<?
$var =$_POST[var];
Echo ($var);
?>
As you see on picture above, variable can be used in other page. This method is very useful for input from user when you use webpage that use login form.
Subscribe to:
Post Comments (Atom)
Currently have 0 comments: