PHP or PERL CGI

Associate
Joined
3 Oct 2004
Posts
68
Location
Biggin Hill
I want to have a go at building a website which will interact with a database, probably MYSQL. I have done a little Perl but it seems that most people would use PHP for this. What would I be better having a go with Perl or PHP? Any advice would be gratefully received. I have a lot of SQL and PL/SQL experience if that helps?
 
Associate
Joined
27 Dec 2005
Posts
97
PHP is a more modern framework, you would probably find your knowlege more future proof if you learnt it.

I've had problems running CGI on one particular server that ran out of memory- each time a script is called it spawns a new process. I don't think PHP has this problem as it runs as one process that can take many clients.

Also there is going to be more built in functionality to help you with common tasks in PHP than Perl.

Justin
 
Associate
Joined
26 Oct 2002
Posts
1,714
JustinW said:
PHP is a more modern framework, you would probably find your knowledge more future proof if you learnt it.
With Perl 6 coming with a proper OO framework, I'd say they are about equal there.

JustinW said:
I've had problems running CGI on one particular server that ran out of memory- each time a script is called it spawns a new process. I don't think PHP has this problem as it runs as one process that can take many clients.
The only time I've run a webserver out of memory was trying to parse a 80mb XML file for someone, which ended up been a problem with one of the Perl XML modules (since fixed). Had it working fine in the end by parsing the XML myself rather than relying on a third party module.

JustinW said:
Also there is going to be more built in functionality to help you with common tasks in PHP than Perl.
Justin
You realy should look a CPAN as there seems to be a Perl module for any task you care to mention, and probably quite a few that you wouldn't ;)

dean_e_boy, if you've done some Perl in the past, have a look at the DBI::MySQL on CPAN as it makes MYSQL access from within Perl a doddle.
 
Last edited:
Soldato
Joined
26 Dec 2003
Posts
16,522
Location
London
JustinW said:
PHP is a more modern framework, you would probably find your knowlege more future proof if you learnt it.

Nope.

JustinW said:
I've had problems running CGI on one particular server that ran out of memory- each time a script is called it spawns a new process. I don't think PHP has this problem as it runs as one process that can take many clients.

mod_perl is faster than you can possibly imagine.

JustinW said:
Also there is going to be more built in functionality to help you with common tasks in PHP than Perl.

CPAN, boy!
 
Man of Honour
Joined
31 Jan 2004
Posts
16,335
Location
Plymouth
JustinW said:
I've had problems running CGI on one particular server that ran out of memory- each time a script is called it spawns a new process. I don't think PHP has this problem as it runs as one process that can take many clients.
*Adds petrol to fire*

(But seriously, that's not an issue :))
 
Back
Top Bottom