39 Facts About PHP

1.

PHP is a general-purpose scripting language geared toward web development.

FactSnippet No. 537,223
2.

PHP originally stood for Personal Home Page, but it now stands for the recursive initialism PHP: Hypertext Preprocessor.

FactSnippet No. 537,224
3.

PHP code is usually processed on a web server by a PHP interpreter implemented as a module, a daemon or as a Common Gateway Interface executable.

FactSnippet No. 537,225
4.

Additionally, PHP can be used for many programming tasks outside the web context, such as standalone graphical applications and robotic drone control.

FactSnippet No. 537,226
5.

Standard PHP interpreter, powered by the Zend Engine, is free software released under the PHP License.

FactSnippet No. 537,227
6.

PHP has been widely ported and can be deployed on most web servers on a variety of operating systems and platforms.

FactSnippet No. 537,228
7.

PHP language evolved without a written formal specification or standard until 2014, with the original implementation acting as the de facto standard which other implementations aimed to follow.

FactSnippet No. 537,229
8.

PHP development began in 1994 when Rasmus Lerdorf wrote several Common Gateway Interface programs in C, which he used to maintain his personal homepage.

FactSnippet No. 537,230
9.

Fact that PHP was not originally designed, but instead was developed organically has led to inconsistent naming of functions and inconsistent ordering of their parameters.

FactSnippet No. 537,231
10.

In some cases, the function names were chosen to match the lower-level libraries which PHP was "wrapping", while in some very early versions of PHP the length of the function names was used internally as a hash function, so names were chosen to improve the distribution of hash values.

FactSnippet No. 537,232
11.

Over time, PHP interpreters became available on most existing 32-bit and 64-bit operating systems, either by building them from the PHP source code, or by using pre-built binaries.

FactSnippet No. 537,233
12.

PHP received mixed reviews due to lacking native Unicode support at the core language level.

FactSnippet No. 537,234
13.

PHP 8 is a major version and has breaking changes from previous versions.

FactSnippet No. 537,235
14.

PHP 8 introduced union types, a new static return type, and a new mixed type.

FactSnippet No. 537,236
15.

PHP 8 includes changes to allow alternate, more concise, or more consistent syntaxes in a number of scenarios.

FactSnippet No. 537,237
16.

PHP has three types of comment syntax: marks block and inline comments; or are used for one-line comments.

FactSnippet No. 537,238
17.

Arrays can contain elements of any type that PHP can handle, including resources, objects, and even other arrays.

FactSnippet No. 537,239
18.

PHP defines a large array of functions in the core language and many are available in various extensions; these functions are well documented in the online PHP documentation.

FactSnippet No. 537,240
19.

In lieu of function pointers, functions in PHP can be referenced by a string containing their name.

FactSnippet No. 537,241
20.

So, for example, if a parameter's type is int, PHP would allow not only integers, but convertible numeric strings, floats or booleans to be passed to that function, and would convert them.

FactSnippet No. 537,242
21.

PHP 5 introduced private and protected member variables and methods, along with abstract classes, final classes, abstract methods, and final methods.

FactSnippet No. 537,243
22.

PHP's single-request-per-script-execution model, and the fact that the Zend Engine is an interpreter, leads to inefficiency; as a result, various products have been developed to help improve PHP performance.

FactSnippet No. 537,244
23.

PHP is free software released under the PHP License, which stipulates that:.

FactSnippet No. 537,245
24.

PHP includes various free and open-source libraries in its source distribution, or uses them in resulting PHP binary builds.

FactSnippet No. 537,246
25.

PHP is fundamentally an Internet-aware system with built-in modules for accessing File Transfer Protocol servers and many database servers, including PostgreSQL, MySQL, Microsoft SQL Server and SQLite (which is an embedded database), LDAP servers, and others.

FactSnippet No. 537,247
26.

PHP allows developers to write extensions in C to add functionality to the PHP language.

FactSnippet No. 537,248
27.

The PHP Extension Community Library project is a repository for extensions to the PHP language.

FactSnippet No. 537,249
28.

PHP has a direct module interface called Server Application Programming Interface, which is supported by many web servers including Apache HTTP Server, Microsoft IIS and iPlanet Web Server.

FactSnippet No. 537,250
29.

For example, in addition to those listed above, other SAPIs for the PHP language include the Common Gateway Interface and command-line interface.

FactSnippet No. 537,251
30.

PHP can be used for writing desktop graphical user interface applications, by using the PHP-GTK extension.

FactSnippet No. 537,252
31.

When PHP is installed and used in cloud environments, software development kits are provided for using cloud-specific features.

FactSnippet No. 537,253
32.

PHP is a general-purpose scripting language that is especially suited to server-side web development, in which case PHP generally runs on a web server.

FactSnippet No. 537,254
33.

PHP can be deployed on most web servers, many operating systems and platforms, and can be used with many relational database management systems.

FactSnippet No. 537,255
34.

Originally designed to create dynamic web pages, PHP now focuses mainly on server-side scripting, and it is similar to other server-side scripting languages that provide dynamic content from a web server to a client, such as Microsoft's ASP.

FactSnippet No. 537,256
35.

PHP has attracted the development of many software frameworks that provide building blocks and a design structure to promote rapid application development.

FactSnippet No. 537,257
36.

PHP offers well defined ways for embedding itself into other software projects.

FactSnippet No. 537,258
37.

That way PHP can be easily used as an internal scripting language for another project, providing tight interfacing with the project's specific internal data structures.

FactSnippet No. 537,259
38.

PHP received mixed reviews due to lacking support for multithreading at the core language level, though using threads is made possible by the "pthreads" PECL extension.

FactSnippet No. 537,260
39.

PHP is used for Web content management systems including MediaWiki, WordPress, Joomla, Drupal, Moodle, eZ Publish, eZ Platform, and SilverStripe.

FactSnippet No. 537,261