PHP?

Why would you use PHP over something like Flask or Django? Isn't development faster and code cleaner? I know it's used to maintain old projects but is there any reason to start a new project in PHP?

Attached: PoopHpoop.png (1280x691, 79K)

Other urls found in this thread:

benchmarksgame-team.pages.debian.net/benchmarksgame/fastest/php-node.html
github.com/nikic/scalar_objects
twitter.com/NSFWRedditGif

Because Python is shit and PHP is like C integrated with html?

Why is it shit?

>Slow
>Ugly
>Designed by retards for retards

i'm not gay

The general consensus appears to be that Python is gay compared to PHP

>Isn't development faster and code cleaner
No.

Just avoid php at all costs and you should be good to go. I'd rather use node.js unironically.

why?
Its faster than it was and almost all servers support it.

python is fucking shit, and has tons of pathing issues cron issues environment issues etc. It is fucking unusable if you want to port it around or literally move it in any way other than the base system you have it in
There is NO language as bad as python.
so that is why I'd use PHP over python. Because at least it isn't fucking python.

PHP is not faster than node.js

python is worse in every way vs PHP
also this
wrong. Nodejs is better at the specific things it was designed for (async) vs php, that is all.

You generally shouldn't.
The only good thing about PHP, surprisingly, is the ecosystem. Composer is a pretty good package manager with packagist having a ton of great, mature packages and frameworks like Symfony which are really great to work with.

But the language itself is dogshit. Even though PHP7 has doubled its performance and 7.3 is already 30% faster than that, the zend engine is still an interpreter, which are just bound to be slow. The PHP8 JIT's not looking to be that much faster since the language is filled with horrible design decisions that just make it impossible to generate good code.
The lack of things like function signatures, enums, generics annotations etc. Is bad and the standard library is a minefield where you just have to know which functions are known to be broken or to be broken if you do or don't pass certain parameters.

The situation could be much worse than it is, but PHP still suffers from all the horrible decisions Rasmus Lerdorf made at the very beginning of its life when it was a stack-based templating engine for C with tiny wrappers around C functions and when he thought it would die within 6 months after being replaced with a better, actually engineered solution, which never really happened, especially thanks to mod_perl being insecure and buggy garbage that came way too late.

Attached: 1564652943775.jpg (1029x632, 64K)

>72168484
>wojack
opinion discarded.

>t.pythonista(male)
Well that explains why everything you wrote is fantasy and sounds crazy.

benchmarksgame-team.pages.debian.net/benchmarksgame/fastest/php-node.html
Nodejs is also much faster at quite a few pure calculation programs.

Rather than sperging about which one is better, I want to know, which kind of people build a server with Python?
You're not gaining in computation hours, so the only reason to be using it to gain in development hours, and I get it, being able to quickly develop a functional server is great, if this is your reason I completely understand.
But most of the people interested in deploying a server want it to serve some website, or mobile app, or a game. None of those areas have significant amounts of Python devs, so in this case you're using an unfamiliar environment and not gaining in development hours either.
So, why then?

>Doesn't know how to quote with >>

Opinion credited.

Use whatever the fuck you want

There are quite a few devs doing websites with Python. Isn't Django one of the most popular frameworks out there?
For big sites Instagram is the most known example, they blog about dev adventures sometimes. I'm pretty sure Youtube is a lot of python too.

Having Python in your server is different from serving with Python.
YouTube uses it just to generate video recommendations, which is ultimately computed with C++/Cuda on Tensorflow, so the Python part exists only to make trivial jobs like API calls.

Nope. Nobody uses python for real websites. It's used to do trivial shit instead of using BASH, that's about it.

lmao I've seen production sites using Python
You must be trolling

yea, and they're garbage.
If you have a lot of data they use JAVA to fucking do production sites.

We all know why PHP is shit user, that was not the question

>yea, and they're garbage.
Can't argue with you there lol

why cant they make a long term plan to make the language better? like you could do a 15 years plan of deprecating the current mess
just copy most of c# design or something, a solid type system with a concise api that doesnt have weird behavior like isset/empty, but keep the good parts that make php special (the good kind of special)
like hack but since it's official people would actually care, just in the sense that it could coexist. like maybe even go with a .phpx file or something. so you can veeery slowly port legacy systems to it
its funny that we have buzzwords like serverless while php now tries to shoehorn async and things from other languages

Because PHP is faster, and well written php is just as clean.

just copy typescript without a preprocessor step (no runtime bullshit please)

>PoopHpoop.png
I prefer the nickname poohoop for PHP, personally.

PHP is can be much cleaner than python is in web development.
Python has a lock on how clean it is (and it isn't clean) but PHP can go from absolute shit to great

>is_can
that sounds like a php function alright (I love php tho)

is_array

github.com/nikic/scalar_objects Just one of the many things php needs to be more consistent.

>from 2010
>starts with function where php is faster, which are used often like regex.
>then php sucks in everything else compared to node but these are all function nobody ever uses, like mandelbrot.
Nicely retarded. Now do the benchmark with php 7.3 and the newest node.

No point if you don't heavily clean up the language like .
Right now you have a heavily inconsistent language full of weird behavior and they keep adding features that make the situation even worse. And you already have 10 ways of doing the same thing. And 90% of the SPL was a failure or is a nightmare to work with.

>Composer is a pretty good package manager
It can't even deal with multiple versions of a dependency properly.

why wouldn't you use c# and razor instead of php? why not use vuejs? why, why, why.
php is dead, kiddo.

a developer with half a brain would never touch anything from microsoft, that includes vscod(e|dium)

Yes, but neither can PHP itself, unless you're willing to have your package manager literally rewrite source code to change namespaces.

i couldn't care less about your opinion, neet.

VersiĆ³n 7 is acceptable.

>php is dead, kiddo.
Surely some of these "website in a box" sites disagree

Except people who need to get shit done

You can do more in Linux. I haven't made the switch out of laziness. But one of my laptops runs Ubuntu but the fstab is really messed up or something because it won't boot properly. Idk man, I'm a dumbass. I'll be freedom fighting software in no time done worry baby ;)

>async
So pretty much everything a modern web app needs unless you're living in the 2000s and easily replaced with word press

laravel is pretty cool tbqh

when people unironiucally think that php 7 is slower than fucking js

Client side js is not that slow

Node scales up to being faster than even java on large enterprise projects once the project becomes big enough.

PHP is much faster to develop anything web based like APIs and microservices in.

There are very good frameworks, tonnes of libraries, everything is supported.

It's also very fast.

>Why would you use PHP

jews made it and it doesn't cost anything yet

good post
t. python dev

Attached: 1559487503623.jpg (566x358, 38K)

Bullshit. Express/node is faster, has tones of libraries, fast without a garbage syntax

I'm only learning, but I used it for my last class project. We (team of 5) needed to our first mobile app ever upp and running with a basic CRUD back end. So instead of fighting over what to use, we used the solution that seemed easie and faster to set up.
I don't regret it, because the back end was so simple, but it felt like building a house of cards. It felt incredibly fragile.

such a fucking degenerate.

How could you even survive up to this day

reddit.com, you fucking imbecile degenerate, is python

As a PHP dev (that actual holds a job as a PHP dev).

No, use Rust/Go/Python for all i care.

The only 2 "redeeming" factor of PHP as of now is the mainstream use of certain CMS and Frameworks, ie(Wordpress, Laravel).

Also the community is getting more influenced by the JS community by the day. Which doesn't always match with the core value of what the PHP was in the beginning. (though this is mostly seen in framework/cms).

See the Wordpress Gutenberg review score on the plugin listing for a reference (or laugh). "wordpress: /plugins/gutenberg/#reviews"

Bloated, slow, lacking clear direction, lacking good standards (especially community wise).

> It will get you a job: "Yes"
> Will you love your job: "Maybe if you're a masochist"
> What are you doing atm instead of killing urself user: "C/Cpp/Rust"

laravel is pretty good though.

why though? basically any lang built prior to concepts like event loops are bound to be configuration nightmares.

python is a fucking joke, especially for webdev. if you don't believe me, read the instagram medium posts where they talk about shit like disabling garbage collection for preforking gunicorn workers.

php suffers from a lot of the same bullshit. you'll just end up wasting time shoehorning some fucked up preforking bullshit or language mangling event loop into it.

if you want to script a web shit up, I'd choose something like node at least. not only because google's JIT is extremely good, but because the language was built on the leveraging of an event loop and first class functions and promise patterns for proper IO concurrency.

Did you even try to read it? The source is right there with the language versions. It is php 7.3.5.

The regex one is pure c with ffi, so no wonder it is fast with php. php was built to call c.
Mandelbrot is just for loops and ifs at it's core. So language performance.

youd already be a millionaire or have worse problems when you hit the scale necessary to fix these problems

non of your hipster bs is any relevant. You will not be running world most visited websites ever.

Python is fine because on default it can handle more than enough traffic on the cheapest VPS. On the plus site it has the cleanest and the shortest syntax from everything mentioned ITT which is actually what matters

Attached: 1559282568584.png (400x389, 48K)

>the cleanest and the shortest syntax
As expected of retarded frogposters, Python was not made for web development, PHP was, therefore you need no libraries nor bloat to get it running and python syntax is aids.

go back please.

You must have some sort of brain tumor to imply php syntax isn't aids.

>C syntax is aids

Only shit developers and frontend web faggots think php is bad, for all the same reasons they think C is bad.

As a PHP dev who switched to Python I can say they are both on their way out. JS Everywhere is the future, sadly.