Learn  PHP Echo 


PHP echo is statement to print the String ,multiple lines strings ,Variables and ,Arrays etc.In upcoming lessons you will see there is big role of Echo in PHP .

Example Printing Single string:

<?php  
echo "Hi my name is Akshay Dhiman";  
?>  
Hi my name is Akshay Dhiman

Example Printing Multiple string:
<?php
echo "Hi my name is Akshay Dhiman. This is multiline example .Hi my name is Akshay Dhiman. This is multiline example .Hi my name is Akshay Dhiman. This is multiline example .Hi my name is Akshay Dhiman. This is multiline example
";  
?>  

Output:
Hi my name is Akshay Dhiman. This is multiline example .Hi my name is Akshay Dhiman. This is multiline example .Hi my name is Akshay Dhiman. This is multiline example .Hi my name is Akshay Dhiman. This is multiline example


If you want to use more than single parameter, you have to use the parenthesis.

Example Printing Multiple Parameters:
<?php   
void echo ( string $arg1 [, string $... ] )  
?>  
Example Printing Variable:
<?php
$Variable="I am Akshay Dhiman";  
echo $Variable;    
?>  

Output:

I am Akshay Dhiman

If you have problem using echo ,Pelase watch this Video.




Last Updated: 2018-07-06 12:32:44 By akshay

SHARE THIS

share_facebook share_twitter share_google_plus

Please Comment Here :