I couldn't find the reference page in the book, but if you're using, for example: <FORM METHOD=POST in the calling script (ie HTML), then just use a variable declaration at the beginning of the called script (ie PHP) using the
$IncomingVariable = $_POST["IncomingVariable"];
format.
Same goes with METHOD=GET:
$IncomingVariable = $_GET["IncomingVariable"];
As an example, in Chapter 3, the text.html example is sending the $Author variable to text.php. The METHOD=GET is used, so you might have this typed in the text.php file:
$Author = $_GET["Author"];
The variable getting the assignment: $Author could easily be named $IncomingVariable, but the second Author (in quotes and brackets) would match the name of the variable sent.
Later chapters talk of other methods of passing variables as well.
Oregon
|