I dimly remember that "proper" Unicode support was planned for PHP 6, and being one of the features that delayed that version, and contributed to it being skipped altogether.
A look at modern PHP
281–290 of 610 posts
Re: A look at modern PHP
#282Earlier quoted context omitted.
PHP isn't being replaced by Rust or Go. It's being replaced by Medium, Wix, and Squarespace. At this point, the predominant reason it's still undergoing active development is that there is a metric ton of legacy PHP code. As the businesses still using it either mature, evolve, or fail, the need for PHP will begin to dry up. You're defending the language from an emotional standpoint. > choosing php for a new project i…
> PHP isn't being replaced by Rust or Go. It's being replaced by Medium, Wix, and Squarespace. Funny that you mention Squarespace as replacing PHP when they themselves are a big PHP shop.
This is evidenced in their open-source GitHub projects: https://github.com/squarespace
Re: A look at modern PHP
#283The amount of misinformation, false claims and unsupported statements in this thread is mindblowing for the quality that I've been used to see on HN. Here are some facts: - Symfony was the backend framework with the most contributors in 2019 [1] (yes, out of any backend framework written in any language) - PHP has more active contributors than it ever had [2] - Laravel is one of the most used frameworks in the world…
I think, the reason is, Facebook poured a load of money/time into PHP. Otherwise it would probably on life-support right now.
Re: A look at modern PHP
#284The amount of misinformation, false claims and unsupported statements in this thread is mindblowing for the quality that I've been used to see on HN. Here are some facts: - Symfony was the backend framework with the most contributors in 2019 [1] (yes, out of any backend framework written in any language) - PHP has more active contributors than it ever had [2] - Laravel is one of the most used frameworks in the world…
"PHP only exists today because of legacies being maintained" I think, the reason is, Facebook poured a load of money/time into PHP. Otherwise it would probably on life-support right now.
Re: A look at modern PHP
#285Earlier quoted context omitted.
Some people simply have reasonable standards. I tried for years to hire a PHP dev. I never found a single one. I found tons of people who had PHP on their resume, and not a single one of them was anything close to competent. PHP only makes hiring easy if you don't care about the quality of work that gets done. I can hire a million PHP monkeys, but everyone who has the right combination of intelligence and conscientio…
You can hire "good programmers" and ask them to write PHP - Facebook does
Re: A look at modern PHP
#286Earlier quoted context omitted.
One of the main benefits of PHP for web serving, is the "shared nothing" architecture. By operating as a non-threaded application, entire categories of bugs and security holes are avoided. Are there situations where threads could genuinely help? Sure, there is always an exception to any rule, but for the vast majority of projects where PHP is used, I don't believe threading would achieve much in terms of performance…
Yeah, but if you're worried about bugs and security holes, I'm not sure PHP can possibly help more than it hurts. E.g., type juggling: https://www.netsparker.com/blog/web-security/php-type-juggli...
The first example in that article even highlights that `in_array` has a `$strict` parameter.
I'd bet a months salary it's easier to teach developers to use strict comparisons (either through arguments to be passed, or strict operators to be used) than it is to teach developers how to avoid thread-safety bugs.
Re: A look at modern PHP
#287The amount of misinformation, false claims and unsupported statements in this thread is mindblowing for the quality that I've been used to see on HN. Here are some facts: - Symfony was the backend framework with the most contributors in 2019 [1] (yes, out of any backend framework written in any language) - PHP has more active contributors than it ever had [2] - Laravel is one of the most used frameworks in the world…
"PHP only exists today because of legacies being maintained" I think, the reason is, Facebook poured a load of money/time into PHP. Otherwise it would probably on life-support right now.
Re: A look at modern PHP
#288Earlier quoted context omitted.
Sure, but sometimes X is something like you have a video and you want to use the GPU to analyze it and the best library for that is in C and there are great python bindings. So a professional developer would use C or Python and not waste his client time by trying to create it's own unmaintainable CoolLang bindings (where this dev is just now learning CoolLang and there are not that many people that know CoolLang). Ev…
You can do this in Spring Boot/ Java, with one Java class and one config file. And it will likely be an order of magnitude more scalable & reliable than the PHP, having proper logging, security features, etc. Whereas such PHP systems in my experience tend to be unreliable, in need of maintenance and often broken. The Java/ Spring Boot option will also take you all the way to a high-end commercial system/ large websit…
It will also be probably faster then a Java framework since you don't have a function call stack 30 levels deep (not a Java issue , all magic frameworks including PHP one have such giant call stacks)
Re: A look at modern PHP
#289Earlier quoted context omitted.
The thing I hate about php is the inconsistency and unpredictability for new-to-php developers. camelCase? snake_case? nocase? Who knows what the global function will be. And who knows what order the arguments should go in. Sometimes the array is first, sometimes not (in array iterating functions like map). The thing that got my goat the most however was that referencing an undefined variable merely caused a warning,…
FYI when you start a PHP project you need to change your dev machine php.ini to be super strict, so all warrnings should just error out. The inconsistency seems to have it's logic and at that time was consistent and made sense, you need a good IDE to help with this. Using PHPStorm and then using PHPDoc to define your functions parameters and return type is a joy, the IDE will catch your type mistakes, show you where…
Re: A look at modern PHP
#290PHP, Python and Ruby all feel to me like last-generation languages. IMO we should be building new frameworks on modern languages that support concurrency & static typing. The most promising new stack I've seen is Kotlin's KTOR framework. Thanks to the expressiveness of Kotlin it's not really any more verbose than something like PHP or Ruby but it's far more powerful and robust.