Thursday, July 21, 2016

How to create simple PHP page?

What is PHP?
"PHP: Hypertext Preprocessor". PHP is a freeware scripting language. PHP is server side scripting language. It is powerful for making interactive, faster, and dynamic web pages. To create PHP one should know basic about HTML, CSS and JavaScript. A simple PHP example is given below. It is widely used and it compete with Microsoft’s ASP in market.

Why PHP?
Fast Load Time – PHP is much faster than ASP because it runs with its own memory space while ASP uses overhead server.
Less Expensive Software – Working with is almost because software like wordpress are open source and free to use while ASP is costly compare to PHP.
Database Flexibility – There are many DB that can be used with PHP most commonly used is My SQL. MySQL is also open source and free. Other DB like dBase, IBM DB2, Inter Base, Front Base, ODBC, Postgre SQL, SQLite, etc. are also supported.

How to use PHP?
Set Up PHP on Your Own PC
However, if your server does not support PHP, you must:
  • install a web server
  • install PHP
  • install a database, such as MySQL
The official PHP website ( has installation instructions for PHP:



echo "<h1>starting with PHP..!!!</h1>";


  • A PHP script starts with   <?php   and ends with   ?>.
  • The default file extension for PHP files is ".php".
  • "echo" is a built in php function that help to output in our case text ” starting with PHP..!!! is printes


Other interesting things to know?

It can be used to design any type of website and can handle websites with a lot of traffic. Facebook, Twitter, Wikipedia and many other very widely visited websites are made from PHP.

It has a readable and easily understandable syntax. Its code is embedded in the HTML source code and it is based on C/C++. Therefore, it is very familiar and programmers are very comfortable coding with it.

It can be run on all major operating systems like Linux, UNIX, Mac OS and Windows.

It uses its own memory space and thus decreases the loading time and workload from the server. The processing speed is fast and web applications like Ecommerce, CRM, CMS and Forums are also developed faster by it.

It has multiple layers of security to prevent threats and malicious attacks.

It has a large community of developers who regular and timely updates tutorials, documentation, online help and FAQs.

It is being used since close to two decades now since its inception in 1995. It is trusted by thousands of websites and developers and the list is increasing day by day. It has also proven its capability and versatility by developing and maintaining some of the most highly visited and popular websites.
Post a Comment