Re: is PHP a neccessary evil?
By: LaRRy LaGoMoRpH to All on Sun Oct 12 2014 20:37:35
I don't like php - but it seems to be all over the place. It seems like if want to do web development work, they want you to know php.
But in a perfect world, is PHP neccessary or even ideal to do the things it' used for moving forward? Maybe it is, I don't know.
It seems very database oriented - like you better know SQL if you know PHP o else you're kinda missing something.
Then there's all the darn ?'s and $'s all over the place that don't make thi any easier to read. Sure those things are nifty when it's jquery tacking on javascript, but as a core element of the language seem to make it more difficult to read.
PHP seems to have grabbed a huge chunk of the market share, yeah. It seems to be most evident in places where the servers are trying to be kept 'lean 'n mean', though. I mean, if you're looking for a really fully-featured suite, with inherent container-based security, you're going to go into JSP, ASP, or [I think there is] another one that I can't remember offhand. Those environments are absolutely obese; they make your server requirements skyrocket.
Perl, python, and shell scripts (as well as native code executables) work, but they just don't have any inherent security in them. You've really got to be on your toes to make your own application executed directly from the webserver.
This doesn't seem to be the case as much with PHP, though I know that it still shares some facets of the same risk. The problem I've had with PHP, though I've used it to write some apps, is pretty much what you're talking about. It's a 'dirty' language. Reminds me more than a bit of Perl, except at least Perl knew what the hell STDOUT was for. When you couple that with the horribly duct-taped together OO syntax (at least last time I checked, which was nearing 10 years ago), and some of the other fugly options, yeah... It gets kind of nasty.
The ?'s, I believe, are more due to the nature of the inline parsing w/HTML, and what the webserver requires in order to find the script. Not sure, though, maybe you're talking about something else.
As far as the $'s, are you talking about in variable instances?
Anyway, yeah, I don't use PHP if I can help it, which has kept my hands clean for damn near a decade now. I'd totally sell out on that if it'd get me back into IT right now, though.
---
þ Synchronet þ Tinfoil Tetrahedron BBS telnet or ssh -p 2222 to tinfoil.synchro.net