PHP is a short name of Personal Home Page or stands for Hypertext Preprocessor. It is a server side, HTML embeded scripting language used to create dynamic web pages.
Much of its syntax is borrowed from C, Java and Perl with some unique features thrown in.
In HTML pages, PHP code is enclosed in special PHP tags. When visitors open the pages, the server processes the PHP code and then sends the output (not the PHP code itself) to the visitor's browser. This means php code is not like JavaScript code which people can copy from our site and use it on their site.
PHP offers excellent connectivity to many databases including MySQL, Informix, Oracle, Sybase, Solid, PostgreSQL, and Generic ODBC. The popular PHP-MySQL combination (both are open-source products) is available on almost every UNIX host. Being web-oriented, PHP also contains all the functions to do things on the Internet - connecting to remote servers, checking email via POP3 or IMAP, url encoding, setting cookies, redirecting, etc.
There are many versions of PHP, what different(s) between them?
PHP4: added to several enterprise-level improvement to the language, including the following:
- Improved resource handling.
- Object-oriented support: a degree of object-oriented functionality is incorporated in version 4, although it was largely considered an unexceptional and even poorly conceived implementation. Nonetheless, the new features played an important role in attracting users used to working with traditional object-oriented programming (OOP) languages. Standard class and object development methodologies were made available in addition to features such as object overloading and run-time class information.
- Native session-handling support: This feature offered developers a means for tracking user activity and preferences with unparalleled efficiency and ease.
- ISAPI support: ISAPI support gave users the ability to use PHP in conjunction with Microsoft’s IIS Web server. A later joint collaboration between Zend and Microsoft greatly improved IIS’ PHP support using FastCGI.
- Native COM/DCOM support: Another bonus for Windows users is PHP 4’s ability
to access and instantiate COM objects. This functionality opened up a wide range of interoperability with Windows applications.
- Native Java support: In another boost to PHP’s interoperability, version 4 offered support for binding to Java objects from a PHP application.
- Perl Compatible Regular Expressions (PCRE) library: The Perl language has long been heralded as the reigning royalty of the string-parsing kingdom.The developers knew that powerful regular expression functionality would play a major role in the widespread acceptance of PHP and opted to simply incorporate Perl’s functionality rather than reproduce it, rolling the PCRE library package into PHP’s default distribution.
- Vastly improved object-oriented capabilities:Version 5 includednumerous functional additions such as explicit constructors and destructors,object cloning, class abstraction, variable scope, and interfaces, and a major improvement regarding how PHP handles object management.
- Try/catch exception handling: Devising error-handling strategies within this problem, version 5 added support for exception handling. Long a mainstay of error management in many languages, such as C++, C#, Python, and Java, exception handling offers an excellent means for standardizing your error reporting logic
- Improved XML and Web Services support: As of version 5, XML support is based on the libxml2 library; and a new and rather promising extension for parsing and manipulating XML, known as SimpleXML, was introduced.
- Native support for SQLite: Always keen on providing developers with a multitude of choices, support was added for the powerful yet compact SQLite database server (www.sqlite.org). SQLite offers a convenient solution for developers looking for many of the features found in some of the heavyweight database products without incurring the accompanying administrative overhead.
No comments:
Post a Comment