Introduction to PHP


  • PHP is one of the most popular server side scripting languages running today. It is used for creating dynamic web pages that interact with the user offering customized information. PHP offers many advantages; it is fast, stable, secure, easy to use and open source (free).
  • Rasmus Lerdorf wrote the first PHP (first called Personal Home Page) scripts as a series of Perl scripts that he used to track visitors to his webpage and to see who was viewing his resume. He eventually rewrote PHP as a scripting engine and added support for forms. PHP has been evolving since 1994 as an open source code. A community of followers and developers formed and began using and further developing PHP. Over the years the Personal Home Page acronym was dropped and it evolved into the PHP Hypertext Preprocessor.
  • PHP code is inserted directly into the HTML that makes up a website. When a visitor comes to the website, the code is executed. Because PHP is a server side technology, the user does not need any special browser or plug- ins to see the PHP in action
  • PHP doesn’t use a lot of the system’s resources so it runs fast and doesn’t tend to slow other processes down. It is typically used as an Apache module, written in C, so it loads and executes quickly. It works well with other software and can be quite fast. PHP is also fairly stable and since it is open source, the PHP community works together to fix any bugs. The community offers technical support and continuously updates the code further expanding PHP’s capabilities.
  • PHP offers many levels of security to prevent malicious attacks. These security levels can be adjusted in the .ini file.

Advantages:

  1.   PHP is accessible
  2. It's available for free 
    1.    It's available with documentation in many languages 
    2.    There are many support groups, forums, and teams supporting PHP 
    3.    There is a wealth of online information regarding PHP
  3. It's quick to develop in PHP. a basic PHP script can be created without a firm understanding of  programming principals, compilation, and other currently important programming concepts.
o   PHP is loosely typed, which makes basic scriptsmuch faster to develop with less attention to design
4.  Programmers of Java, PERL, BASIC, and other popular languages can find many parallels to ease transition to PHP
5. PHP is flexible. Use OOP or not. Use naming convention(s) or not


6.  It runs on many different operating systems
7.  It can be optimized, even "compiled" for performance closer to that of more established compiled languages

Disadvantages:

 1 Out of the box, PHP tends to execute more slowly than assembly, C, and other compiled languages
Ø  PHP is loosely typed. For developers of all skill levels, this allows room for unexpected behavior due to programmer error that many other languages might not permit. [Of course, few if any languages can protect from developer error!]
There are many ways to do one thing and many cases where a function has ambiguous handling dueto legacy support or PHP development history.

No comments:

Post a Comment

=>Advanced Java Programming (J2EE)

1.  Syllabus 2. Unit Wise Question/Material 3. Paper 4. Previous Paper