Live data from Hacker News

Go with PHP

gowithphp.com

281–290 of 532 posts

Re: Go with PHP

#281

Earlier quoted context omitted.

Making "complex tasks seem readable and intuitive to the layman" is no bad thing - besides other engineers, future you could become a 'layman' easily. Readable, expressive code is something I've come to value highly after almost 20 years And from first-hand experience, while the specific code sample shown on this page shouldn't be treated as a practical example of how to architect a larger application, there's nothin…

I guess I wasn't clear enough? I said "it makes complex tasks SEEM". My point being, they SEEM SIMPLE in a DEMO. But in real application it quickly turns into a quagmire, due to the problems I already listed. Oh look, you even say so in your own comment: "the specific code sample shown on this page shouldn't be treated as a practical example". So... you're saying the page makes it SEEM simpler than IT IS, hmm? Is thi…

I have one name for you: Symfony

More or less directly opposite of what Laravel is preaching. It's the popular choice for anything that is being build long term. It is very popular in Europe and we have a far bigger community around it than Laravel does.

Re: Go with PHP

#282

Earlier quoted context omitted.

The issue is that there is so much configuration that it’s basically coding. PHP frameworks are all bloat. It would have been much better to abstract things in a way that you actually spend time on features not thousands of configs.

Then use lumen, it comes with laravel.

Nah, I’ll use python or other proper languages, thanks.

Re: Go with PHP

#283
I've been using PHP for about 19 years and what I can tell is that both the language and its community have evolved the right way. Writing modern PHP is a joy, IDE support is great and we have tools for everything.

Modern PHP is about community standards, not about any particular framework and exposing Laravel as the best way to get started with PHP is questionable. I wouldn't recommend it to anyone wanting to learn (real) PHP.

The article praises PHP but it is sad that doesn't link to any other resource or project which ditches the value of PHP community.

Laravel is great for RAD which is attractive for small projects. The kind of stuff "business with 500K orders runs on a $6 VPS" thing. For clients wanting a robust software system you can use a better tool.

Re: Go with PHP

#284
post #17

As a fullstack developer who has worked many, many years in the javascript hellhole, I mean ecosystem, as well as the python ecosystem and .NET; coming back to PHP the last 2 years, working essentially in Laravel and the like - I couldn't approve more of this message. Seriously, PHP is the grand father that will drive you to class and you'll never be late, the car will never smell and everything will always just be f…

> It's single threaded

You could make it single threaded. But the standard is multi threaded, and if you have more then 100 users will be have to deal with locks.

That said, locks/threads are still easier to manage then async code.

Re: Go with PHP

#285

Earlier quoted context omitted.

> PHP has matured and has been a nice language for a decade now. And how did it manage that? Python forced people to deal with encodings properly and the result was a lot of pain. You're claiming PHP somehow invisibly fixed the numerous problems of the language without anybody noticing? That "fractal of bad design" blog post, everything described in it has been fixed? If so I want to learn how they did it. That's som…

Encodings are a non issue in PHP and the availability of web tools is much wider in php than for python. PHP matured in the sense that it from a wordpress type of hacky language to an almost decent language. It can be used properly if you know what you are doing (ie can scale really well for the web, can be secure, allows for good oop design, can be fast _for the web_, and has a wide range of supported packages, sepa…

> and the availability of web tools is much wider in php than for python.

If that was a metric for language quality, then Javascript would be undeniably the most perfect language ever designed by any intelligent species in the universe, judging by the number of frameworks.

> to an almost decent language

And now I would like to hear a good reason why I should use an "almost decent language", when I can use a decent one instead.

> It can be used properly if you know what you are doing

It doesn't matter what I do, the language still insists of having multiple modes of error handling, a massive amount of builtins all of which sit in my global namespace, it's configuration is still seperated between compiler flags, a system wide ini, and local config. The base deployment mode is still "dump files into folder and let CGI do the rest".

Re: Go with PHP

#286
post #17

As a fullstack developer who has worked many, many years in the javascript hellhole, I mean ecosystem, as well as the python ecosystem and .NET; coming back to PHP the last 2 years, working essentially in Laravel and the like - I couldn't approve more of this message. Seriously, PHP is the grand father that will drive you to class and you'll never be late, the car will never smell and everything will always just be f…

Have a look at quarkus. Thanks to JVM you have really good out of the box debugging features including hot code replacement and profiling. You can use kotlin which is a really really good language in comparison to PHP. There is no need in my opinion to write real applications with PHP.

In my experience Laravel teams are WAY more productive than Quarkus teams though.

Re: Go with PHP

#287

Earlier quoted context omitted.

Exactly. array_filter and array_map, have different order of arguments. ($array, $callback) vs ($callback, $array) A small example of how inconsistent the language is from the ground up. Most people can explain their respective web servers, but I've never heard anyone even come close to what PHP/Laravel is actually "doing". Side Complaint: If you are working with Laravel Queue, it is such a hassle to reload your code…

So what's the programming language that's 100% consistent? For example Python isn't.

I doubt any language is at 100% but from my work with them Elixir, Golang and Rust are predictable and a joy to use. I don't remember the last time their API has surprised me.

Re: Go with PHP

#288
post #107
post #36

Earlier quoted context omitted.

Most of the stuff we do now we do with "Laravel Livewire". It's quite brilliant really, even for modals etc. "look ma, no javascript!". Of course it does JS for you, you just don't see it. That's my favourite kind of Javascript - someone else's problem. Livewire is a mid-way between front-end backend, it's a progressive back-end with long polling like NextJS I suppose. From your end though, it takes care of all the s…

> it's a progressive back-end with long polling like NextJS I suppose It’s kind of funny that this is the new best thing, when this is almost the same model JSF did decades ago.

[deleted]

Re: Go with PHP

#289
post #107
post #36

Earlier quoted context omitted.

Most of the stuff we do now we do with "Laravel Livewire". It's quite brilliant really, even for modals etc. "look ma, no javascript!". Of course it does JS for you, you just don't see it. That's my favourite kind of Javascript - someone else's problem. Livewire is a mid-way between front-end backend, it's a progressive back-end with long polling like NextJS I suppose. From your end though, it takes care of all the s…

> it's a progressive back-end with long polling like NextJS I suppose It’s kind of funny that this is the new best thing, when this is almost the same model JSF did decades ago.

It just had so many other issues with its ergonomics that this nice innovation was lost in the weeds a bit.
Post reply on HN