|
Quick Intro to PHP Development
|
By Alan Grissett
[Hits: 21981]
|
|
Chances are that if you¡¯ve been around the Internet long enough,you¡¯ve heard of server-side scripting languages such as PERL,ASP and ColdFusion. These are all popular languages that areused to add interactivity to Web sites, but one stands out fromthe crowd in terms of usability, power, and, yes, price: the PHPscripting language. Initially developed in 1995 by NorthCarolina programmer Rasmus Lerdorf, PHP has since blossomed intoone of the leading open-source, cross-platform scriptinglanguages available. This is due, in large part, to theworldwide community of coders that contributes to itsdevelopment. Unlike proprietary scripting languages like ASP andColdFusion, PHP¡¯s source code is freely available for peerreview and contributions. This is, of course, the essence ofopen-source software development, but why is it that PHP inparticular has gained such popularity among Web developers whenthere are other open-source alternatives, such as goodold-fashioned PERL CGI scripts?
One very strong reason is that PHP, unlike PERL CGI scripts, isscalable and fast. Instead of requiring the server to start anew process in the operating system¡¯s kernel for each newrequest, which uses both CPU time and memory, PHP can run as apart of the Web server itself, which saves a considerable amountof processing time when dealing with multiple requests. Thisdecreased processing time means that PHP can be used forhigh-traffic sites that cannot afford to have their performancehampered by relatively slow CGI scripts.
In addition to its scalability and speed, another usabilityfactor that sets PHP apart is its ease of use. The PHP languageis considered to be a mix between C and PERL, and it draws fromthe best features of each parent language, while adding uniquefeatures of its own. For example, PHP code can be embeddedwithin standard HTML documents without using additional printstatements or calling separate scripts to perform the processingtasks. In practice, this allows for very flexible programmingpractices. Although a working knowledge of HTML is aprerequisite for PHP development, PHP¡¯s basic functions can belearned quickly and applied to a wide range of commonWebmaster-related projects, such as order forms, e-mailresponses, and interactive Web pages.
Contributing to the power of the PHP language, is its nativesupport for leading relational database platforms, includingMySQL, Oracle and PostgreSQL. Platform-specific functions arebuilt into the language for 12 databases in all. This nativesupport for database platforms is a boon to any site that needsto track user information, store product data, or collect salesinformation.
Last but not least, because PHP is open-source, it isessentially free to use. Almost all professional Unix-based Webhosts offer PHP as an included option with hosting accounts. Besure to check with your host to see if it is available to you.
This article is meant to be an introduction to the PHP languageand not a tutorial, but have no fear¡ªhere are several first-ratesites that have articles that will guide you along in beginningyour PHP development projects:
www.php.net www.onlamp.com/php/ www.phpbuilder.com
|
|
|
|