PHP is more evolutionarily fit than Perl in a handful of very important ways (I would illuminate, for example, function signatures and a pre-built object system, syntactically trivial nesting of data structures, and a newcomer-friendly out-of-the-box execution model).
That said, I wrote Perl for years as a hobbyist (still do, now and then), and have spent the last 6 or so primarily writing PHP. There is not a day that passes that I don't miss some aspect of the rich, expressive, elegant, sophisticated, and intellectually delightful environment that is Perl at its best.
It is a doomed and sinking continent, Perl, but if we let the considerable wisdom of its once-great civilization evaporate into trite dismissal, we as a culture stand to lose a great deal.
I had heard they were finally fixing that, which is why I made my comment a reference to the past. I'm glad they settled on a syntax that wasn't too far out of the norm from what you would expect, given PHP's roots (i.e. Perl). I seem to recall the RFC at some point had a different syntax, but I could be remembering incorrectly.
I'd think the mixing of associative and sequential arrays are one of the key things that lowers the barrier to entry though.
For me it fails the "similar things should look similar, different things should look different" test. Then again, they aren't really all that different in PHP. I guess it comes down to me preferring my sequential and associative data structures to be separate, which is a fairly fundamental difference to how PHP thinks it should be. I have a sneaking suspicion that the complexity this data structure tries to hide leaks out through the numerous functions used to interact with it[1], which just shifts the pain slightly farther down the line, and possibly from a one-time event (when learning the fundamentals) to a regular occurrence as it causes problems continually later.
PHP doesn't insist on the array() keyword, currently. The mixing of associative and sequential arrays is ambiguous, although you can think of them all as being associative; it's just, PHP will supply some keys if you don't provide any. Whether that's kludgey or acceptable is up for discussion. (I don't mind it at all.)
Like Perl, PHP is a long-lived, heavily-used-in-production language, which means there is a lot of cruft that has accumulated over the years that's difficult for the platform developers to just slough off. But much like there is a Modern Perl movement that has coalesced around voluntarily cutting out cruft and using a much cleaner, nicer-to-work-width subset of Perl, there is a similar movement in PHP-land that's doing the same thing.
PHP The Right Way (http://www.phptherightway.com/) is a good place to start if you're curious what "modern PHP" looks like.
This. Nobody taken seriously in PHP world doesn't use modern PHP tools, Good frameworks, Composer, follow PHP-FIG standards, all that stuff... Just because you had to maintain a PHP4 app 10 years ago, doesn't mean PHP hasn't changed. And it also doesn't mean real devs don't have standards and follow up-to-date guidelines.
For sure. WordPress has a lot of legacy backwards compatibility on its shoulders. If they could shrug it off and start again, I'm sure it would be a lot cleaner.
The project I'm working on (https://github.com/idno/idno) is PHP, but explicitly doesn't support legacy versions, in order to rule out the way of working that was finally made obsolete in v5.3. I'm very happy with the language, and I can usually express what I need simply. Reflection could use a little love, mind you.
I'm building some projects that are only targeted at 5.5 -- once you do that, and stick to all the PSR standards, then it's actually really nice, super productive, and the cruft that exists gets ignored. I like PHP still shrugs
True. But Wordpress is a blogging engine with tons of stuff bolted on to make it behave like a CMS. It appeals to the same group of people that disable error reporting to make their spaghetti code work.
I do a lot of PHP programming. Frameworks like Laravel are a godsend. Sometimes I have to work on a Wordpress project and it makes me cry.
Python is elegant, and my first real commitment to a language, but imo nothing beats Haskell in elegance (though scheme has a certain beauty about it). Perhaps this is just me being temporarily enamored though, I can't help but to link to this post:
Haskell and I have been doing well so far in the "RealWorld" and I hope it keeps going that way :D If not, I'll probably put more time into python and C again.
I personally don't feel that I've struggled with monads that much. Perhaps that was because I was okay with "I know how to use monads or wrestle them into getting something to work" (took 20 minutes) until I got to "I understand what monads are for, I understand how to compose them, and I can see how they aren't a hindrance and in many cases are useful." (has taken 4-5 months on/off learning).
I haven't ran into memory issues yet, but I have heard others have a very hard time reasoning about memory/space leaks. However, something I hear less often is that the memory problems people have also happen in other languages.
It might be better than Perl, but not by much.