Next Previous Contents

32. Appendix D - PERL versus PHP debate

PERL (Practical Extraction and Reporting Language) is kind of ancestor of PHP. PERL is immensely powerful and is in use for a very long time, just like "C" language. PERL can do everything that "C" language does. You are better off programming in PERL than in "C" language!! Most of the "C" programmers prefer to program in PERL if speed is not that important (C programs is little faster than PERL).

PERL5 is fully OOP operational. Just because PERL can also do everything without OOP techniques does not mean it's not OOP.

Comparing PERL to PHP, in terms of readability and scalability, they are nearly equal although PHP has a slight advantage for those who insist on using only client side code. PERL is certainly easier to read than C due to it being a very high level language. As you know, the biggest obstacle to multiple developer maintenance is compilers from which PERL does not suffer.

PHP and PERL are equal in these ways:

  1. High level code. English-like syntax is easy to read and logical
  2. Execution speed. As raw interpreted source code, both are very fast (compared to VB and the like.)
  3. Ease and speed of development. As scripts, both can be developed quickly bypassing the nasty compiler and with built-in intelligent debuggers.
  4. Run anywhere. A dream these share which all other languages fail.
  5. Superior text processing to all other languages.
  6. Open source.
  7. Both are very well supported by whole Internet community
  8. Both are free.

Where PHP has an advantage over PERL:

  1. Client-side code (for those who insist on such things.)
  2. Easier to compile into EXE.

Where PERL might have an advantage over PHP.

  1. PERL is already installed on every web server in the world automatically during setup.
  2. PERL is more backward and forward compatible.
  3. PERL in all it's versions is VERY stable.
  4. PERL hooks into all existing dbase engines very easily. The necessary modules come with every PERL distribution. All that is required is up-to-date drivers which are easy to obtain. PERL and MySQL are made for each other.


Next Previous Contents