What is PHP Syntax?
The following is a sample of PHP
script. Type it in your notepad and save it as testPHP.php. Then FTP it into
your server. Remember, you can not running it as client-side. Your host provider
should support PHP, too. Also, make sure you have .php extension.
The following PHP module checks your
PHP capabilities of your server; and shows you the features of PHP that are
supported by your hosting provider, such as databases, image creation, etc.
Notice that each statement must be terminated with a semicolon (;).
<!DOCTYPE html PUBLIC
"-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitionl.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta
http-equiv="content-type" content="text/html; charset=iso-8859-1"
/>
<title>Welcome to the
iSelfSchooling PHP example page!</title>
</head>
<body>
<?php phpinfo(); ?>
</body>
</html>
|