What is PHP
PHP (PHP: Hypertext Preprocessor) is a widely used open source general-purpose scripting language that is especially suited for web development. PHP was developed by Rasmus Lerdrof in 1994.
Here are some features of PHP that makes it one of the popular languages in world of web development.
- PHP is capable of managing dynamic content, databases, session tracking, e-commerce sites and web applications.
- It is very easy language for beginners but have also offers a lot of advanced features for professional programmers.
- PHP scripts run on server.
- PHP is an open source programming language.
- It is widely used with MySQL database but can also be integrated with other popular databases including PostgreSQL, Oracle, Sybase, Informix, and Microsoft SQL Server.
- PHP supports all major web servers including Apache and IIS etc.
- Major protocols like POP3, IMAP, and LDAP. are supported by PHP
- PHP can run on all major platforms like Linux, Windows and Mac.
What are common uses of PHP.
PHP can produce dynamic content. Unlike HTML static pages when some visitor access a PHP based site for example it a user access Facebook (which is a dynamic web site), she is presented with new content every time consisting of updates, message and shared content from other users. HTML or a static site cannot do this.
We can quickly develop fairly large web applications written in PHP
PHP can open,read, write, files on the server. It can collect from based data, read and write cookies, insert and read data from a database and a lot of other functionality that we will discuss and perform in upcoming posts.
PHP can be installed on windows, Linux and Mac Operating Systems.
We need a Wen server, PHP it self and a DBMS like MySql to start working on PHP.
For installing all of these software we will use WAMP (Apache, Mysql, PHP on Windows OS). you can download this software from http://www.wampserver.com.
Instruction to WAMP.
“WampServer is a Windows web development environment. It allows you to create web applications with Apache2, PHP and a MySQL database. Alongside, PhpMyAdmin allows you to manage easily your databases.”
Installation instructions are given on Wamp web site as allows.
- Double click on the downloaded file and just follow the instructions. Everything is automatic. The WampServer package is delivered with the latest releases of Apache, MySQL and PHP.
- Once WampServer is installed, you can add other releases by downloading them on this website. They will then appear in the WampServer menu and you will be able to switch releases with a simple click.
- Each release of Apache, MySQL and PHP has its own settings and its own files (data for MySQL).
- The “www” directory will be automatically created (usually c:\wamp\www)
- Create a subdirectory in “www” and put your PHP files inside.
- Click on the “localhost” link in the WampSever menu or open your internet browser and go to the URL : http://localhost
We will start learning PHP from next post in this series