Introduction to PHP, purpose, history, versions

Introduction to PHP: History and Versions

This article discusses a detailed introduction to PHP, a powerful server-side scripting language. You will know “What is PHP?”, PHP & HTML interaction, the main uses of PHP language, PHP & MySQL interaction, and version history.

What is PHP?

PHP is a recursive acronym for “PHP: Hypertext Preprocessor”. It is a general-purpose scripting language based on C, Java, and Perl that is extensively used in web development. PHP can be easily embedded into HTML documents, unlike other programming languages. The main purpose of PHP is to provide a solid platform for web developers to generate dynamic web pages. PHP provides great value to static HTML documents in the long run.

PHP is different from client-side scripting languages such as JavaScript in which code is executed on the client side. All PHP code is executed at the server level that’s why it is also known as a server-side scripting language. Whenever a client requests certain information on a PHP web page, the client’s user agent sends that request to the web server. The web server parses the PHP code and sends the required information back to the user agent in the form of HTML documents. The user agent presents that information to the client, with the client knowing absolutely nothing about the underlying code.

Web developers can use PHP on all major operating systems such as Microsoft Windows, macOS, Linux, Unix, and many others.

What is PHP used for?

Web developers use PHP mainly for server-side scripting to create dynamic web applications. Developers can use PHP to:

  • Output HTML files, PDF files, or animated movies generated dynamically
  • Store and retrieve data from databases
  • Dynamically generate web pages content
  • Register and login users on websites
  • Collect form data
  • Encrypt data
  • Send and receive cookies
  • Manage users’ sessions on websites
  • Allow users to submit data on a web application
  • Manage files uploaded by users
  • Create blog posts and archives
  • Build an eCommerce store
  • Allow users to make purchases on eCommerce websites
  • Develop content management systems e.g. WordPress, Drupal, Joomla, etc.
  • Develop eCommerce management systems e.g. Magento, PrestaShop, OpenCart, etc.

Developers use PHP for many other purposes in addition to the above-listed goals such as command-line scripting. Some developers also use PHP to create desktop applications, although it is not the very best language for this purpose. In addition, PHP has support for LDAP, IMAP, SNMP, POP3, HTTP, and many others. Furthermore, the ability to parse and access XML documents is of great use. Developers can also use Java objects as PHP objects.

PHP, MySQL, and other databases

PHP can interact with a lot of databases such as Firebird/Interbase, MongoDB, IBM DB2, MySQL, PostgreSQL, SQLite3, SQLSRV, OCI8, dBase, and CUBRID, etc.

The long-standing relationship between PHP and MySQL is widely used in web development. PHP interacts with MySQL to store and retrieve information from databases, and for many other purposes.

History of PHP

Early history

Firstly created by Rasmus Lerdorf in 1994 as a simple “Personal Home Page/Forms Interpreter or PHP/FI”, PHP has evolved into one of the most powerful & dynamic server-side scripting languages used to create web applications. Generally, PHP/FI could be used to create simple and dynamic web pages. However, to accelerate bug fixes and improve the code, Personal Home Page Tools (PHP Tools) version 1.0 was released on June 8, 1995. The language resembled C and Perl as it had C like structure and Perl like variables, interpretation of forms, and HTML embedded syntax. Since then, PHP has grown by leaps and bounds. In November 1997, Rasmus released PHP/FI 2.0 by adding built-in support for databases, cookies, user-defined functions, and much more.

PHP 3.0 to 8.0

To counter inefficiencies and limited personal use of PHP/FI 2.0, Andi Gutmans and Zeev Suraski, started a complete rewrite of the underlying parsing engine. Meanwhile, Andi, Rasmus, and Zeev decided to collaborate in the development of a new, independent programming language. Their efforts materialized into the release of a new PHP 3.0 in June 1998. Since then PHP has grown by leaps and bounds.

In order to improve the performance of complicated applications and to improve PHP code, Suraski and Gutmans, then, started rewriting the PHP’s core leading to the development of “Zend Engine” in 1999. At this point, in May 2000, PHP 4.0, powered by Zend Engine 1.0, was officially released along with additional features. The PHP development team released PHP 5.0, powered by Zend Engine 2.0 in July 2004. PHP 6.0, initiated in 2005 to add Unicode support to language was officially abandoned in Mar 2010 due to a shortage of developers and performance problems.

Dmitry Stogov, Xinchen Hui, and Nikita Popov refactored the Zend Engine to improve the performance of PHP. The redesigned Zend Engine was renamed as Zend Engine 3.0 because of significant changes. Accordingly, a new PHP version named as PHP 7.0, based on Zend Engine 3.0, was released in December 2015 which included major internal changes and additional features.

Finally, on 26 November 2020, the PHP development group released PHP 8.0, powered by Zend Engine 4.0, with breaking changes from previous versions. Notable changes included “Just-in-time compilation”, the addition of the “match” expression, and others.

Supported PHP versions

VersionInitial ReleaseActive SupportSecurity Fixes
8.026 Nov 202026 Nov 202226 Nov 2023
8.125 Nov 202125 Nov 202325 Nov 2024
8.28 Dec 20228 Dec 20248 Dec 2025
Source: php.net

Unsupported PHP versions

VersionEnd of LifeLast ReleaseStatus
7.428 Nov 20227.4.33Unsupported
7.36 Dec 20217.3.33Unsupported
7.230 Nov 20207.2.32Unsupported
7.11 Dec 20197.1.33Unsupported
7.010 Jan 20197.0.33Unsupported
5.631 Dec 20185.6.40Unsupported
5.521 Jul 20165.5.38Unsupported
5.43 Sep 20155.4.45Unsupported
5.314 Aug 20145.3.29Unsupported
5.26 Jan 20115.2.17Unsupported
5.124 Aug 20065.1.6Unsupported
5.05 Sep 20055.0.5Unsupported
4.47 Aug 20084.4.9Unsupported
4.331 Mar 20054.3.11Unsupported
4.26 Sep 20024.2.3Unsupported
4.112 Mar 20024.1.2Unsupported
4.023 Jun 20014.0.6Unsupported
3.020 Oct 20003.0.xUnsupported
Source: php.net

Now that you have learned about the introduction, uses, and history of PHP, it is a good time to learn some practical skills such as installing and configuring PHP.

Similar Posts

Leave a Reply

Your email address will not be published. Required fields are marked *