[fpc-pascal] CGI (with Free Pascal) vs PHP

Florian Klaempfl florian at freepascal.org
Tue Mar 6 13:21:41 CET 2007

Chuck Burkins schrieb:
> On 3/6/07, Florian Klaempfl <florian at freepascal.org> wrote:
>> (Pascal) compiler based CGI is magnitudes faster than PHP, less resource
>> consuming and much easier to maintain. The only advantage of PHP is that
>> is easier to use for beginners and that's probably the only reason why
>> PHP is so popular: you can hack quickly something together but
>> maintainance, performance etc. are nightmares.
> With all due respect (and that *is* a lot of respect), I disagree. I
> leave out the relative speed of PHP vs. compiled pascal, as I've never
> use Pascal in CGI. I have got over 100,000 lines of PHP code in
> service, so I think I can safely comment on that.

I agree that you can write good code in PHP as well as one can in Perl
but it requires a lot discipline and most people don't do so in PHP and
Perl while pascal forces them to do so. Probably one of the reasons why
Pascal and Ada aren't that popular.

> PHP does not in any way burden a modern web server, at least when used
> as an apache module. 

Well, feel free to solve our problems with mantis ;) I know a lot of
other people permanently fighting with the load of their servers and
I'am rather sure the only reason is the resource wasting of PHP.

> PHP written by  skilled programmers can be quite readable and
> maintainable. Certainly easier in my eyes that C and miles ahead of
> Perl. It is true that PHP is easy for beginners to pick up, but Pascal
> is actually easier for beginners in my opinion,  

Pascal doesn't allow you hack together something like PHP allows. A
pascal based web application is harder to write than a PHP one. See above.

More information about the fpc-pascal mailing list