Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

[flagged]



I haven't used PHP in years.[1]

That said PHP gets a lot of undeserved flak and also even if it is not the best tool for everything, - if you end up using it you definitely should know how to use it to your avantage.

[1]: Java is so nice and low ceremony these days and even .Net can now update dependencies without running exe files and clicking next-next-agree-next and I also prefer typed languages a lot.


Yet this internet myth of "PHP no bueno" persists.

Don't confuse the tool with the artisan. PHP is an incredible language that's getting more mature with each new release.


I'm definitely not the fondest user of PHP. There is an extreme gap between the users and the ones being able to develop the language. That gap for example, is a lot smaller in Golang.

Language improvements didn't happen until Hack started being a thing. The performance was a shitshow for 20 years until they got help from Intel engineers. Some of those fixes were extreme low hanging fruit, simple profiler based optimizations -- again, why was this not picked up sooner, imo due to said gap.

Also the community has a severe case of Stockholm syndrome. Always on the extreme defense of the language and the big frameworks (Symfony, laravel). It's a community which shuns other languages and makes fun of Enterprisey Java solutions, yet the average project made in Symfony reminds me of one thing, Java Enterprise projects. The practical difference being they swapped XML for YAML.


Why do PHP developers insist on calling themselves artisans?

Give me a call when PHP ditches backwards compatibility and cleans out all the shit from the standard library - 5845 global functions always available, most of which you are just supposed to know are shit... Just a nightmare.


As the one who did the comment, I've never seen or heard PHP devs calling themselves artisans. My phrasing was an analogy. What I meant was, don't confuse PHP with the bad practices that were propagated for years from careless devs.


Artisans = Laravel dev. Is a complete sub-type of phpc.


First time I've heard of that. The only thing that rings a bell is the artisan command in Laravel


Artisans? First time I hear that. I certainly use PHP and never called myself an Artisan.


It comes from Laravel (https://laravel.com/); "The PHP Framework for Web Artisans". The command line entry point is also called "./artisan".


Isn’t "software craftsman" rather common? And artisan is just a synonym of craftsman. This is nothing specific to PHP. There people out there who take pride in delivering code that was created more as a piece of art.


(ˈɑːtɪˌzæn, ˌɑːtɪˈzæn) NOUN, denoting or relating to goods produced on a small scale using traditional methods

Checks out!


Which by the way is heavily mocked by PHP developers actually using OOP, dependency inversion, hexagonal architecture etc. Which is not the "artisanal" way of development it seems :)


Mocked as in made fun of? Personally (in 7 years as a PHP dev) I've not found this. There was one company I interviewed at where the lead engineer thought facades were dumb, but then couldn't explain why he needed to rebuild the entire backend in Node. Perspective.


Yes, made fun of. Philosophy of Laravel crowd seems to be similar to "the rails way", which means a lot of framework-specific solutions, disregard for TDD etc.

Well, static service locators disguised as "facades" are a bad design. Rebuilding entire backend in Node for that reason alone is dumb. Laravel features a PSR-compliant DI container and supports dependency injection with autowiring, you can very well write a nice, decoupled, SOLID code using Laravel. But it's rather not the thing people have in mind when picking it over Symfony or Laminas.


You can of course take a TDD approach with Laravel. I think I know what you're getting at, but I do find the Laravel has a lot out of the box now that I would otherwise have to write from scratch. I suppose the Spatie packages (for example) fill some of those gaps. I hadn't heard of Laminas before


Laminas is Zend rebranding :)


Why would you care how many global functions there are in PHP? Just namespace your own functions and the whole "issue" will instantly disappear.


Do you think the problem is that I want the function name mysql_real_escape_string for myself? No, I just don't want thousands of confusingly named, completely worthless and/or actively harmful functions to always be in scope.


> No, I just don't want thousands of confusingly named, completely worthless and/or actively harmful functions to always be in scope.

Again, why would you care whether some functions that you don't use are available should you want to use them someday? It's not as if there's a huge list of thousands of functions stapled to the beginning of all your code files that you have to scroll for 5 minutes before reaching your code.




Consider applying for YC's Fall 2025 batch! Applications are open till Aug 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: