Posts ($_POST) is used to take information from a form to the next screen (passing it along). You name the feild and then that becomes the name you will call back. For example:
The Name there is quantiy. Therefore when the feild is carried over you can call back the variable using:
$quantity = $_POST['quantity'];
?>
Ensure you use '' ( $_POST['quantity'] ) for statements and either use (int) or take them out for numbers:
Statment
$quantity = $_POST['quantity'];
?>
Number
$quantity = $_POST[quantity];
?>
Also a Number
$quantity = (int)$_POST['quantity'];
?>
in php used for one typ website
we cant use set timeout function in php because it is of java script function
Below is a simple example of how you could return a value in a PHP function. <?php function returnme($value) { return $value; } echo returnme('hello'); // outputs: hello ?>
function function_name() { .................... }
The eval() function evaluates a string as PHP code. http://us.php.net/manual/en/function.eval.php
A simple function call <html> <body> <?php if(isset($_POST['button'])) { setValue(); // Function is called } function setValue() { echo "<br>The button property to call PHP function works"; // Your code here } ?> <input type="submit" name="button" onclick=<?php $_SERVER['PHP_SELF']; ?> /> </body> </head>
chdir() PHP function helps in changing the current directory.
It gets options from the command line argument list. It can be used in PHP 4.3 and above, including PHP 5.
The PHP website has a comprehensive online manual that can explain most aspects of PHP, including its installation. See the related links for a constantly-updated PHP installation guide.
With a call to the function func_num_args().
header() is a php function used to modify and set HTTP headers sent to the browser.
To rename a file in PHP the easiest way to do it is to use the rename() function. <?php rename("before.txt", "after.html"); ?>