How a PHP program look like

PHP programs are saved in a file with extension “.php”  ( we can use it in .html files also , that I will explain other posts ).

PHP scripts will be in between <?php and   ?> tags.

<?php  is the starting tag ( where our php program in the page starts ) and ?> ending tag ( where our php program ends ).

PHP programs are embedding in between html codes and we can use the html codes inside our php programs also.

Basically a PHP program page will look like

<html>
<body>
<h1>How a PHP program look like<h1>
<?php
/* Here is a block of PHP codes in page */
?>
<h2> HTML portions </h2>
<?php
/* Here is another block of PHP code /*
?>
</body>
<html>

Here we can see that we can use any number of blocks of PHP codes with a mixture of HTML codes  in a page with starting and ending tags of PHP.

What is PHP and Full form of PHP ?

Full form of PHP is Hypertext Preprocessor

PHP is the most popular and widely used server side scripting language for web development. It is used to make the Dynamic pages in websites.

Rasmus Lerdorf was the creator of PHP in 1995.

PHP codes are embedding in HTML source codes for making the page dynamic. PHP can deal with most of the requirements in web development like Database, File handling, String operations, Arrays, Graphics, File Uploads, Data processing etc.

PHP can be used in any operating system with a web server Supports PHP. Apache web server is one of the popular web server dealing with PHP + MySQL. Moreover PHP is absolutely free to use.

Share
Share