Subscribe Twitter

Tuesday, April 26, 2011

Learning php

Php is pre hypertext processor, which is used to write server side scripting. It is easy to code in php and php has a very good libraries as any other normal programming language.

1. Hello World in php

Source code:

?php 

/*......................................................... author:www.codershandbook.in............................... .........................................................*/ echo "Hello world in php"; ?> Output: Hello world in php Code Explanation:

The source should contain less than symbol before php is the body of the php source code closed by the later ?greater than symbol. The echo is the function that outputs the text within the quotes. The file should be saved with .php extension and the output can be viewed in the browser. But you need to install php onto your system. The simple installation is wampserver which can be downloaded from Wamp Server.

Thanks for reading.

0 comments:

Post a Comment