4 ms·
It's an awkward, haphazardly designed, weirdly implemented and frankly ugly beast of a language which just happens to be better suited to its task (server-side
by krapp 12y ago
It's an awkward, haphazardly designed, weirdly implemented and frankly ugly beast of a language which just happens to be better suited to its task (server-side HTML templating) than other more beautiful and elegant languages, none of which are hated by anyone.
- ElectronCharge 12y ago"It's an awkward, haphazardly designed, weirdly implemented and frankly ugly beast of a language" You should have stopped there. :-) Viva Scala!
- krapp 12y agoWell, I suspect part of the reason some people hate it so much is also that so many other people don't. It feels somehow unjust that such an ugly language basically took over the web. But then again, what was the other option, Perl? Evolution picks a direction and runs with it.
- wvenable 12y agoPHP's "standard library" is mostly just a collection of other open source C libraries and exposed the C API with very little transformation. For example, people point to the mysql_real_escape_string() function as an example of bad PHP design but that function comes straight from the MySQL C API[1]. Early PHP was really just a scripting language interface to C and the Web. And from that it evolved very quickly picking up all kinds of technologies along the way. [1] http://dev.mysql.com/doc/refman/5.1/en/mysql-real-escape-string.html http://dev.mysql.com/doc/refman/5.1/en/mysql-real-escape-str...
- ElectronCharge 12y ago"It feels somehow unjust that such an ugly language basically took over the web." That's not really right, though. There are a ton of languages fighting for the server side web development crown. I'd argue that if you limit it to LAMP, Python is a lot nicer than PHP. Regardless, my current vote is for Scala world domination. Let the haters hate. :-)
- _RPM 12y agoHave you actually read php-src? In my opinion there are many clever design patterns used to create the language.
- code_duck 12y agoThe implementation being clever in parts does nothing for the language itself.
- _RPM 12y agoWhat you just said makes absolutely no sense.
- dangrossman 12y agoPerhaps you misunderstand his comment? You might write an elegant and clever Lisp implementation of Brainfuck. That doesn't make Brainfuck an elegant or clever language to program in.
- _RPM 12y agoMaking the implementation faster would most certainly benefit the language itself. There is a logical fallacy in his statement and I was just making that clear for the record.
- code_duck 12y agoThe design of a language and the performance of programs written in that language are fairly separate issues. Of course they combine to create the overall value of PHP, but it's like... To use an auto analogy... imagine a really uncomfortable car with no cup holders that has amazing transmission performance. When I say 'the language itself' I mean the interface as presented to a programmer, not a sysadmin.