Why you should use PHP

  Рет қаралды 25,102

PHP Annotated

PHP Annotated

Күн бұрын

Let's take a quick run through modern PHP.
Timestamps
00:00 Intro
00:24 Typed properties
00:25 Readonly properties and readonly classes
00:27 Promoted properties
00:28 Null coalescing
00:29 Nullsafe operator
00:30 Short arrow functions
00:32 Match operator
00:34 Named arguments
00:35 First-class callables
00:36 Variadic functions
00:38 Array spreading
00:39 Array unpacking
00:40 Performance
00:48 Fibers
00:49 FFI
00:53 Generators
00:57 Type system
01:00 Type variance
01:01 Return types
01:02 Scalar and nullable types
01:03 Built-in types
01:08 Union types
01:09 Intersection types
01:10 Disjunctive normal form types
01:12 Typed properties
01:14 Static analysers
01:22 Generics
01:23 New in initializers
01:25 Anonymous classes
01:27 Spaceship operator
01:29 Trailing commas
01:30 Better exception handling
01:35 Hashing and randomizer libraries
01:38 Redacted parameters
01:39 WeakMap
01:40 Traits
01:41 Attributes
01:43 Enums
01:53 Frameworks
02:20 CMS
02:23 Templating engines
02:25 QA tools
02:36 Packagist
02:40 PHP Foundation
Links shown in this video:
- New in PHP 8.3: stitcher.io/blog/new-in-php-83
- Symfony: symfony.com/
- Laravel: laravel.com/
- Queue management with Laravel: laravel.com/docs/10.x/horizon
- Symfony CMS: symfony.com/projects/category...
- Payments with Laravel cashier: laravel.com/docs/10.x/billing
- JetStream for bootstrapping your Laravel app: jetstream.laravel.com/3.x/int...
- Pest for testing: pestphp.com/
- Laravel mails: laravel.com/docs/10.x/mail
- Taidwind: tailwindcss.com/docs/guides/l...
- Livewire: laravel-livewire.com/
- Inertia.js: inertiajs.com/
- Bref for serverless PHP: bref.sh/
- Roadrunner for async PHP: roadrunner.dev/
- Wordpress: wordpress.org/
- Magento: business.adobe.com/products/m...
- Drupal: www.drupal.org/
- Blade: laravel.com/docs/10.x/blade
- Twig: twig.symfony.com/
- Rector for automatic upgrades: getrector.com/
- PHPStan for static analysis: phpstan.org/
- Psalm for static analysis: psalm.dev/
- PHP CS Fixer: github.com/PHP-CS-Fixer/PHP-C...
- Packagist and composer: packagist.org/
- The PHP Foundation: thephp.foundation/
Timestamps:
00:00 Intro
00:19 Syntax
01:46 The Community

Пікірлер: 104
@phpannotated
@phpannotated Жыл бұрын
Leave a 👍like if you love PHP! What's your favorite feature? Let me know! 👇
@SultanovAsrorbek
@SultanovAsrorbek Жыл бұрын
nullsafety, randomizer
@mayanksgajjar
@mayanksgajjar Жыл бұрын
For me type system ☺
@hsemix
@hsemix Жыл бұрын
A couple of them actually but Fibers stands out for me
@mortezaayashi9581
@mortezaayashi9581 Жыл бұрын
Type system of course
@salmanisfalcon
@salmanisfalcon Жыл бұрын
CodeIgniter. First love of many PHP developers in PHP World.
@nfinzer22
@nfinzer22 Жыл бұрын
Been writing PHP for over 20 years. It just keeps getting better.
@epicgameryt4052
@epicgameryt4052 Жыл бұрын
Started as a 12 year old scriptkiddie in PHP, now a $100k free lancer at 23. PHP is just simply freakin' awesome! (Great work on the new PHPStorm 3.3 btw, it's absolutely amazing!)
@wiwidwidyanto3203
@wiwidwidyanto3203 Жыл бұрын
Hey If you don't mind answering, where do you freelance?
@epicgameryt4052
@epicgameryt4052 Жыл бұрын
@@wiwidwidyanto3203 I freelance for clients. Setup a portfolio, make yourself visible and you'll find them.
@helloworld7796
@helloworld7796 Жыл бұрын
Most of us did I guess. In the time where forums where the only place to learn and weird irc stuff
@jonathanllemit
@jonathanllemit Жыл бұрын
hey bro can I contact you and be my mentor?
@tiagooliveira14
@tiagooliveira14 Жыл бұрын
Truly, PHP is awesome this days!
@Chemaclass
@Chemaclass Жыл бұрын
PHP is one of the best choices to start any web development project.
@wildfireDZ
@wildfireDZ Жыл бұрын
Null safe operator is the best thing that ever happened
@ojsojs6004
@ojsojs6004 11 ай бұрын
PHP Ecosystem keeps growing. Now we have NumPower. NumPower library was created to provide the foundation for efficient scientific computing in PHP, as well as leverage the machine learning tools and libraries that already exist and can benefit from it. This C extension developed for PHP can be used to considerably speed up mathematical operations on large datasets and facilitate the manipulation, creation and operation of N-dimensional tensors. The area of ​​image processing and computer vision will also be able to benefit from this library. Some features of NumPower are: * GPU and CPU compute support * Dozens of different operations for manipulation, arithmetic, linear algebra, statistics and etc. * Single precision float points (float32) for improved memory usage * Custom CUDA kernels for almost all operations * AVX2 support when available on hardware * Support for GD images in RGB format for easy image manipulation.
@rahulxcr
@rahulxcr Жыл бұрын
Php is evolving greatly. Love the updates and performance has also increased.
@vinceAmstoutz
@vinceAmstoutz Жыл бұрын
Thx Brent, this format is amazing!
@mikedub
@mikedub Жыл бұрын
Thanks for this video! Much appreciated for a quick reference.
@enkiimuto1041
@enkiimuto1041 Жыл бұрын
THank you for this video, I'm coming back to PHP for a few things and this video really helps.
@MauroBonfietti
@MauroBonfietti Жыл бұрын
Nice Video! 👍😃🥰
@HaraldEngels
@HaraldEngels Жыл бұрын
I am now using PHP since 17 years and it never has let me down. It was always quite easy to update my code-base (3.000+ classes) to a new PHP version. My code-base is nowadays relatively type-safe and uses most of the new features of the language. I also like that the syntax is close to C. I dislike languages without brackets for control-structures like Python or Ruby. If you have learned PHP it is also easy to use Dart/Flutter to develop mobile apps. One thing is clear, PHP is here to stay. The only thing which concerns me is the slow visible progress of development since PHP 8.2. I hope this will speed-up soon.
@vasiovasio
@vasiovasio Жыл бұрын
Hello Harald. Are these 3K classes open source or only for your private use? Any chance to share them with us?
@Edvard-Aliev
@Edvard-Aliev 11 ай бұрын
Ivan left the development of php, which he had been working on since he was 13 years old! Therefore, he slowed down a lot and his future is not known ...
@martinh4982
@martinh4982 Жыл бұрын
Unrecognisable is right! I do a lot of new development, mostly in Laravel. But I also support a set of old-school - yet to be redeveloped - sites originating from 15+ years ago. Every page is a php file, with html, php, javascript, and css in the same page. Very little, if anything is shared and the duplication is massive. Some pages use bootstrap, some use jquery, some use PDO and others MySQLi and there are some that use an even older DB connection technology. I've yet to find a Class anywhere. Nothing can be tested without going to the actual page... and all code changes are made directly on the production server! It's like being in two different universes!
@chinmoyktamal2837
@chinmoyktamal2837 Жыл бұрын
Great!
@jaydeepgoswami909
@jaydeepgoswami909 Жыл бұрын
Amazing ❤. I've been working with PHP since 2013, and I'm the one who always advocated about PHP. Today also I really love to spread awareness about PHP and it's qualities. This will surely help me and all this who have very little knowledge on what PHP is capable of. It will help me continue spreading awareness.
@DevAmirull
@DevAmirull 9 ай бұрын
Informative video, thank u so much. please continue this kind of video.
@nightmare-vt9uw
@nightmare-vt9uw Жыл бұрын
good job
@mortezaayashi9581
@mortezaayashi9581 Жыл бұрын
Awesome video👌
@phpannotated
@phpannotated Жыл бұрын
Thanks!
@AfmpJR
@AfmpJR Жыл бұрын
That was fast! I almost couldn't keep up. In fact, I have to watch it 6 more times 😅
@sevidmusic
@sevidmusic Жыл бұрын
thank you for making this video. I have loved working with php for years, it has come along way. The language is so much more expressive than it once was. 🤘😎🤘
@patricknelson
@patricknelson 11 ай бұрын
Never thought I’d learn so much in a 3min video 😅
@dundavey
@dundavey Жыл бұрын
I learned so much making my own "framework" when i was little, it took me 4 years to finish it so at the end i was a teenager, the problem however is that i was a kid, didn't know how to market it, or anything related to hosting were pain in the butt. Its archived now on my github page and after that whole situation i felt like php lost its charm and i started doing backend with node, and eventually was a part of the js community. and to be happy with it is the best peace knowing you still made a masterpiece, no one HAS to know
@gromett
@gromett Жыл бұрын
You just made me work out how many years I had been playing with PHP. 25 years. Jeez. 1998/99 I started playing with PHP3. Extremely fond memories of those days. But you just made me feel old 🤣 PHP really has come on a long, long way since then.
@goktugerol1127
@goktugerol1127 Жыл бұрын
Awesome. I use programming languages like JavaScript(and TypeScript), Python, C#.. But PHP has something I really like about, even t hough PHP is very critisized among lots of developers and sometimes I feel uncomfortable talking about it...
@phpannotated
@phpannotated Жыл бұрын
Just show them this video ;)
@dfordemo981
@dfordemo981 Жыл бұрын
I like the method return types and ?? operator 😋😋
@soniablanche5672
@soniablanche5672 Жыл бұрын
All these changes are cool but what made php actually bearable was composer's autoloader, you no longer had to guess where a certain function or variable or class comes from.
@HaraldEngels
@HaraldEngels Жыл бұрын
Yes, Composer was a breakthrough.
@TheRafark
@TheRafark Жыл бұрын
Not really composer, just auto loading in general.
@limpiadora
@limpiadora Жыл бұрын
This is cool and all, but most of the jobs out there is in old php 7, and also there is something that's annoying about PHP array, case they're used the same way as javascript objects which are mostly type safe thank to typescript, there is a lock of type safety for them, at lest for vscode!
@salmanisfalcon
@salmanisfalcon Жыл бұрын
Laravel became popular only because CodeIgniter was being transferred to new owner, or CodeIgniter needed a new home and Laravel got popular during transfer phase.
@abrahammaleko6600
@abrahammaleko6600 Жыл бұрын
Is there a some sort of books which explains furthers on the modern php features added 🙄
@3ckortreat
@3ckortreat 10 ай бұрын
I wish it was a faster language, you can understand which site using php from loading times, i think new type features will make it faster
@yungifez
@yungifez Жыл бұрын
I write php now and i dont recognize some of what you showed Oh well😂 Maybe the formating
@naranyala_dev
@naranyala_dev Жыл бұрын
missing pure PHP framework/library that embraces PHP itself, minimal starter but rich ecosystem
@aimonext
@aimonext Жыл бұрын
we should make it assembly compilable
@jimbolino
@jimbolino 10 ай бұрын
why the cold shoulder for phan ?
@phpannotated
@phpannotated 10 ай бұрын
I couldn't cover everything, and phan is also pretty small compared to phpstan.
@jmon24ify
@jmon24ify Жыл бұрын
very useful information although went too fast through all the significant changes. I had to pause and rewind, at least, a couple of dozen times.
@TheRafark
@TheRafark Жыл бұрын
That’s the style of the video. A short overview to give you that wow factor and i think it’s very well done.
@ag992009
@ag992009 Жыл бұрын
I need that in written format, too fast to comprehend
@phpannotated
@phpannotated Жыл бұрын
You could turn on captions?
@grinsk3ks
@grinsk3ks 11 ай бұрын
Overall it's a cool language, but very lackluster in DX, documentation and consistency. I also observe that it's quite hard to build performant applications/api's. The Request based nature of php requires layers and layers of caching to be fast. As we all know it's quite easy to break a cache xD
@dundavey
@dundavey Жыл бұрын
are we still on version 5.3?
@asdfghyter
@asdfghyter Ай бұрын
no, we are on 8.3 now
@iUmerFarooq
@iUmerFarooq Жыл бұрын
I'm very confused to choose technology for my career please help me. I want to choose PHP/Laravel and take it for long but I am scared I don't why. To be honest because of this I can not start coding, if possible please give me your opinion why should I go with this tech? Will I get high paid jobs?
@zedmagdy
@zedmagdy Жыл бұрын
search for jobs in your area see which technologies are the most wanted and start learning it
@iUmerFarooq
@iUmerFarooq Жыл бұрын
@@zedmagdy Thanks
@radui7468
@radui7468 Жыл бұрын
Do you know why the php developers have on average the smaller salaries compared to developers of other languages?
@RedStone576
@RedStone576 Жыл бұрын
cuz its a dead language that people have been slowly moving away from
@radui7468
@radui7468 Жыл бұрын
@@RedStone576 We can not say it is dead because there are a lot of projects and web apps written in PHP, a lot of PHP programmers, wrodpress, etc. But there is something related with reputation or maybe something else
@raident29
@raident29 11 ай бұрын
i wrote php 10 years ago when i was still in college, i did not understand any of it. im still using it now using laravel 9 and 10 as a software engineer. i still don't understand half of it.
@oafleming
@oafleming 8 ай бұрын
what is your main language now?
@cbbcbb6803
@cbbcbb6803 11 ай бұрын
These changes were really necessary?
@dfordemo981
@dfordemo981 Жыл бұрын
please dont tell us there is a new version of php 😥😥
@phpannotated
@phpannotated Жыл бұрын
It's coming in November :)
@edmond1314
@edmond1314 Жыл бұрын
You forgot to mention php swool
@key7644
@key7644 Жыл бұрын
All good , all of it , YET they can not get rid of damn $ dollar sign before variable ! that's the most annoying thing about PHP
@phpannotated
@phpannotated Жыл бұрын
You think so? I don't really mind it to be honest.
@RedStone576
@RedStone576 Жыл бұрын
lol its not like you can use the newer php version on the company you're working on
@phpannotated
@phpannotated Жыл бұрын
Why is that?
@IshCaudron
@IshCaudron Жыл бұрын
If you have to ask, you don't know php enough.
@fenix23
@fenix23 11 ай бұрын
Ah, I see your company is maintaining project well. Write Tests, refactor, upgrade, repeat.
@birdbeakbeardneck3617
@birdbeakbeardneck3617 Жыл бұрын
Why i dont use php: I just dont like $var
@gordonfreimann
@gordonfreimann Жыл бұрын
nope
@AnonymousDeveloper1
@AnonymousDeveloper1 Жыл бұрын
I work on PHP/Symfony based projects and I like PHP is still maintaned (I guess in a good direction because it does not throw a lot random features) but to be honest it is not good as it should be. Still, PHP has a lot of things which could be reworked, deprecated, removed, refactored and so on. Still, it lacks of features which other programming languages such as Rust, C# or Kotlin have. Maybe in one day there will be successor of PHP which will be better designed.
@TariqSajid
@TariqSajid Жыл бұрын
laravel is very bloated there should be a light version of laravel. if you test request per second laravel is below 500rps but if you test raw php its around 50k rps
@kfh6474
@kfh6474 Жыл бұрын
There is a lighter version. Lumen
@TariqSajid
@TariqSajid Жыл бұрын
@@kfh6474 its deprecated now
@phpannotated
@phpannotated Жыл бұрын
I don't think 500rps is accurate: kinsta.com/blog/php-benchmarks/#laravel-8800
@TariqSajid
@TariqSajid Жыл бұрын
@@phpannotated they comparing laravel 8 not laravel 10 i checked on 10 version I will test on 8 to see the difference also they change the opcache settings
@TariqSajid
@TariqSajid Жыл бұрын
​@@phpannotated i ran on laravel 8 with php8.2 with opcache settings, env prod and debug false and php artisan optimize that was mentioned in the article i was able to achieve 1k rps, how i can achieve 2k ?
@wiskasIO
@wiskasIO Жыл бұрын
Me suffering learning React: (crying) "What the fck I'm doing with my life omg cringe cringe...🤢😭
@gerard02700
@gerard02700 Жыл бұрын
i will never go back to PHP no matter what
@holylandvideos9859
@holylandvideos9859 Жыл бұрын
why
@ashokbishwas
@ashokbishwas 11 ай бұрын
@@holylandvideos9859 python is easy, get lots of jobs. Php is the best.
@walkingin6375
@walkingin6375 Жыл бұрын
PHP is haram.
@svenyboyyt2304
@svenyboyyt2304 Жыл бұрын
I still hate it. It's not intuitive and the names for everything are terrible, no void or undefined, needs a dollar sign, unintuitive and random syntax, objects and associative arrays, square bracket syntax, no prototype functions for types ([1, 2, 3].map(a => a * 2) like in js), weird arrow functions, needs semicolon etc. It's completely static so you need JS anyway and makes it a lot harder to use JS and using a *hypertext preprocessor* on the backend is a completely stupid idea. And using PHP to generate js code is completely wack thing too. Sure Laravel and stuff exist, but that doesn't make PHP good because it has them. In fact they would be better if they didn't use PHP. Wish someone would make Laravel with Go, a language actually made for server stuff.
@DaviMartins99
@DaviMartins99 Жыл бұрын
Why don't you just use PHP as the API backend and write JS in a complete separete repo like everyone else?
@TheRafark
@TheRafark Жыл бұрын
Those are some of the most BS arguments I’ve read, except for primitive objects.
@dasten123
@dasten123 Жыл бұрын
I'm just glad I don't have to deal with PHP anymore :D
@holylandvideos9859
@holylandvideos9859 Жыл бұрын
what's the main reason I just want to learn
@dasten123
@dasten123 Жыл бұрын
@@holylandvideos9859 to be completely honest... it's the dollar signs and snake_case
@ojsojs6004
@ojsojs6004 Жыл бұрын
​@@dasten123lol. That's bad argument and a trivial reason
@fenix23
@fenix23 11 ай бұрын
And its camelCase if you follow PSR code style guide
@dasten123
@dasten123 11 ай бұрын
@@fenix23 well not the built-in stuff like json_encode(). And when reading other people's code, it's not consistent at all based on my experience.
PHP doesn't suck (anymore)
10:48
Aaron Francis
Рет қаралды 198 М.
Why do big Companies use Java, and NOT PHP?
12:34
Stefan Mischook
Рет қаралды 221 М.
A pack of chips with a surprise 🤣😍❤️ #demariki
00:14
Demariki
Рет қаралды 54 МЛН
She ruined my dominos! 😭 Cool train tool helps me #gadget
00:40
Go Gizmo!
Рет қаралды 59 МЛН
Tom & Jerry !! 😂😂
00:59
Tibo InShape
Рет қаралды 54 МЛН
PHP 8 3 Released
11:03
ThePrimeTime
Рет қаралды 100 М.
Why is Laravel NOT used in Big Development Projects?
11:53
Stefan Mischook
Рет қаралды 170 М.
Golang is OG?
5:16
Martin Baun
Рет қаралды 5 М.
Why Does Scrum Make Programmers HATE Coding?
16:14
Thriving Technologist
Рет қаралды 496 М.
Is PHP the Secret King of Code?
6:42
Stefan Mischook
Рет қаралды 53 М.
How Senior Programmers ACTUALLY Write Code
13:37
Thriving Technologist
Рет қаралды 1,4 МЛН
Interview with Senior PHP Developer
6:12
Programmers are also human
Рет қаралды 346 М.
Is PHP dead in 2022? | Is PHP still worth Learning in 2022?
9:36
Lionel The Tech Lead
Рет қаралды 23 М.
PHP Is Not Dead - Let's Review PHP 8.2 Changes
14:19
Program With Gio
Рет қаралды 45 М.
Laravel Origins: A PHP Documentary
33:27
OfferZen Origins
Рет қаралды 154 М.
A pack of chips with a surprise 🤣😍❤️ #demariki
00:14
Demariki
Рет қаралды 54 МЛН