«« Next » « Previous
«« Next » « Previous

Link Details

Announcement

iPhone DZone: Fresh Links On Your iPhone by matt at Sat Jul 05 14:09:51 EDT 2008

Reading DZone on your iPhone just got a little bit easier. Visit http://dzone.com/iphone from your iPhone to try out our beta iPhone support. You can view stories, filter by tags, and login. We'd appreciate your feedback at feedback@dzone.com.

Open 24/7/365. Never a waiting line! Login and vote now.
Link 63079 thumbnail

By jimbojw
via jimbojw.com
Published: Jan 24 2008 / 09:09

Ugh. I am so tired of defending PHP - even from people I know and respect and who use it every day. So here I'm going to make my last stand. In all future arguments I get into, I will point back to this article as my sole defense.
  • 13
  • 12
  • 1431
  • 660

Comments

Add your comment
User 201118 avatar

Lars Pohlmann replied ago:

2 votes Vote down Vote up Reply

I myself really like php5 as well, but your " Irrelevant complaints" are quite relevant.

- namespaces: I use classes,dude. But in fact the number of classes in use can grow to such an extend in "enterprise-applications" (i know, this word sucks), that even there you'll get into naming-collisions...

- globals: yes, they can pierce through your code, they do it so well, that you'll never find the place again, where you defined the variable... this generates dependencies, that are hard to unravel.

I'll leave it at that.

User 190346 avatar

ilazarte replied ago:

1 votes Vote down Vote up Reply

I definitely miss static typing when working in php. What's "right-click, find-callers" for Java code takes grepping/searching in Php. It really hurts refactoring which is an activity of a few minutes in Java. In Php the mention of it makes the dev team nervous.
,

User 249616 avatar

robse replied ago:

0 votes Vote down Vote up Reply

php5 introduced type hinting. "Go to declaration" and similar IDE commands can therefore be supported.
Don't know if it works in eclipse but it should. Also from what I've heard, namespaces may be coming to php5 soon (also: see http://www.petitiononline.com/phpns/)

Voted down for the "Irrelevant complaints" section

User 212444 avatar

Barry Carr replied ago:

1 votes Vote down Vote up Reply

Voted down because he glossed over many of PHP's deficiencies, namely: inconsistent function naming conventions; having to remember where to use ===, !== and ==, !=; Its got a nasty, nasty syntax e.g. $var and $this-> and last but not least, security.
Plus, as Lars mentioned, his irrelevancies are, indeed, really relevant.

User 212108 avatar

legendx replied ago:

0 votes Vote down Vote up Reply

One is case sensitive.. am I missing something?

User 238392 avatar

davidwalsh replied ago:

3 votes Vote down Vote up Reply

I don't understand PHP haters at all. Each language has its place in the web and it's up to the programmer to decide which is best.

I too dislike the inconsistent function naming, but is it really that big of a deal? And is the comparison syntax really that tough?

To your last deficiency Barry, security is ALWAYS a developer issue. If a developer doesn't write secure code, there will be a problem. Blame the developer for this; not the language.

User 212108 avatar

legendx replied ago:

2 votes Vote down Vote up Reply

PHP's strength and weakness is that it is flexible. Done. The only reason rag on php is because a lot of people write poor code. It's not php's fault that you didn't check for sql injection.

User 191349 avatar

raveman replied ago:

0 votes Vote down Vote up Reply

lol, i never heard anybody attacking php, first i thought that ruby people were fighting against php since ruby is better version of it, but at first chance guy took swing at java, just weird for me.

i like php, there is just something cool about it, however i dont want to read your php code.
,

User 201565 avatar

Rob Lang replied ago:

0 votes Vote down Vote up Reply

It's not a balanced article, it's just a fanboy's rant.

Add your comment


Html tags not supported. Reply is editable for 5 minutes. Use [code lang="java|ruby|sql|css|xml"][/code] to post code snippets.