1. Download an integrated environment software, that is, others put all the chaos seven or eight in a piece, made software, this is the SG-style, I think beginners with this good point;
2. Download and install them separately. Php.zend.apache; This method is the most chaotic, and it is not clear yet.
I am because of the IIS installed on the machine, it is to install a PHP and Zend. Now you can run both PHP and ASP on the server.
PHP is embedded in HTML and runs in the following:
<?php $a = "Hello"; $b = "PHP"; echo $a. $b;?>
Description
Define a variable with a $ variable name, such as $ A on the $b, when referring to this variable is also used to refer to the variable name;
When each statement is finished, add '; ' The number indicates the end;
Output with the Echo output content;
$a. $b, the '. ' The number is used to connect two strings.
The result of the above program is:
Hello, php!.
To output PHP information:
<?php phpinfo ();?>
The IF statement in PHP:
<?php $a =10; $b =1; if ($a = = $b) { echo "a=b"; }?>
The output is:
A=b
MD5 Plus password function, the people who have done the web know MD5, this is just a function in PHP, the call is OK:
<?php $a = "PHP"; $b =md5 ($a); echo $b;?>
The output is:
e1bfd762321e409cee4ac0b6e841963c