Free download web templates, books and more. Free php projects ,games and apps. GTA mods and more

Breaking

Php first programme || pHP example code

PHP first Example programme

It is very easy to create a simple PHP example. To do so, create a file and write HTML tags + PHP code and save this file with .php extension.
All PHP code goes between php tag. A syntax of PHP tag is given below:
  1. <?php   
  2. //your code here  
  3. ?>  
Let's see a simple PHP example where we are writing some text using PHP echo command.
File: first.php
  1. <!DOCTYPE>  
  2. <html>  
  3. <body>  
  4. <?php  
  5. echo "<h2>Hello First</h2>";  
  6. ?>  
  7. </body>  
  8. </html>  
Output:

Hello First