PHP Syntax


PHP Syntax :– PHP syntax is easy to learn. Syntax rules tells us how to write statements, varaiable and functions etc in any programming language. Most commanly used starting and ending tags are respectively. So now here we are going to discuss more specific example for php syntax but before going ahead one thing is to remember is the extension for php file is .php simply means all php files would be ended with .php keyword while saving in any editor.


PHP Syntax | Example

A PHP script syntax is much similar to html unlike some starting and ending tag described as follows:

You can see the following example how php syntax looks inside html code:

Example

<?php
echo "hello php";
?>



Advertisements

Add Comment

📖 Read More