Showing posts with label echo function. Show all posts
Showing posts with label echo function. Show all posts

Saturday, January 3, 2009

Echo Function with example

Php scripting always start with . Php scripting can use anywhere in html file. Just using this tag .
and terminate with
Echo is means of ouputting text to the web browser. To output a string you can place either string variable or you can use quotes . Like we do below:-


$str=”Hello guys!”;

echo $str;

echo “ this is my first php program”;

?>




output:-

hello Guys!
This is my first program.




In php no need to define type of variable and to declare the variable . Like in above program str variable will automatically of type string. If we give some value to str example:- 3 than variable type will be interger.