Vulgar rules html. Rules for writing CSS

To organize the transfer of data from an HTML form to a PHP script, you first need to configure the php.ini file:

register _ globals = on // direct access to form fields by name

error_reporting=E_ALL //report on all errors

display _ error = on //display errors in the document

error_prepend_string=””

//format for errors (opening tag)

error _ append _ string =””

//format for errors (closing tag)

The main rule in connecting an HTML form and a PHP script is to create a variable for each element passed HTML forms. That is, if you have one text field in the form called Text and a Submit button, in the receiving PHP script you no longer need to create a variable for text field and somehow initialize it, since this $Text variable will be automatically created with a value equal to the value entered into the text field.

The form and PHP script can be placed in one document. To do this, you need to specify action="" in action.

Example:

if (isset($im)) (print $im;)