![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Professional Programmer
|
Perl compared to PHP
I've picked up books on both of these, but in the introductions all it really says is that they are good server side scripting tools. They don't really list their functions and limits. What I'm asking, is what are they built for? How do they compare? And what are their limits?
|
|
|
|
|
|
#2 |
|
Programming Guru
![]() ![]() ![]() |
I'll leave the details for someone else to explain... but in my experience... Perl is good for system related scripts while PHP is more suited for web based scripts. (I realize Perl has the ability to utilize CGI, etc).
__________________
http://jasonpowers.net "There are a thousand hacking at the branches of evil to one who is striking at the root." |
|
|
|
|
|
#3 |
|
Programming Guru
![]() ![]() |
Php for web, perl for system scripts IMHO, just like IR.
However you can use php for system scripts as well, but i have never used it for that purpose.
__________________
Profanity is the one language that all programmers understand. Check out my Blog <---updated Nov 30 2007! |
|
|
|
|
|
#4 |
|
Professional Programmer
Join Date: Mar 2005
Location: Glasgow, Scotland
Posts: 317
Rep Power: 4
![]() |
I prefer Perl CGIs to PHP, but I think that's just because I met Perl first. PHP is definitely nice.
In my opinion PHP has a cleaner, simpler syntax and is more approachable; C experience takes you further with PHP than it does with Perl. The way you use PHP is also more familiar to people with ASP experience, and access to commonly used stuff like databases seems so clean and neat on PHP as to be trivial, whereas with Perl it takes a little more work. Hackerish types tend to prefer Perl in my experience; PHP is more popular with people who want to throw down some code quickly and get the job done. To be honest, I don't there's all that much to choose between them if you haven't learned either yet; if you think you'll want to write code that isn't intended to run as a server-side script driving a website then maybe you'd thank yourself later for choosing Perl, but I think you've got a win/win situation with this particular decision anyway.
__________________
"I'm not a genius. Why do I have to suffer?" |
|
|
|
|
|
#5 |
|
Programming Guru
![]() Join Date: Aug 2005
Location: England
Posts: 1,499
Rep Power: 5
![]() |
PHP is a templated based language. PHP code is embedded into the template (which is usually in HTML), and the server PHP module converts the code into text output.
Perl is a more general use language, and showing its age somewhat. However, it's arguably more flexible than PHP, and you can achieve some interesting programming techniques in it. |
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|