yes yes PHP 8. 4 they've been making a great comeback and they might be a cool language they might actually even fall under the cool I think they're a sleeper I think in 2026 you're going to hear a lot about it I'm feeling I'm calling it now I'm saying that PHP sleeper okay uh PHP 8. 4 is a major update of the PHP language it contains many new features such as property hooks asymmetric visibility and updated Dom API performance improvements bug fixes and general cleanup okay I didn't even realize there was a Dom API in PHP okay I didn't know this this is new this is actually new to me all right property hooks okay so let's check out each one of these property hooks class local string language code let's see uh string country code public function do a little construct uh language code this this this okay set language code well crazy code this is crazy you're doing Getters and Setters what is this this is crazy what is this what are we doing here what are we doing here set combined code set combin let's see get combined code what are you doing here okay anyways here we go okay so let's look at this new PHP 8.
4 here we go we have these two wait hold on public string language code public string country code brackets set so they have Setters and Getters now generally speaking generally I'm going to throw this out there I don't like Setters and Getters okay let me defend why let me defend why the simple reason why is look at this statement right here the statement right here is very obvious what has happened we are going to set this country code equal to this right so you can look at this and you can see it and you go okay I understand it what you don't understand is actually this is happening it kind of hides the information away behind the DAT you know what I mean it hides it away there's there's there's a little bit of IND Direction and so when you read this line of code you don't realize that there could be more executing and so generally speaking I've always disliked Setters and Getters I feel like there uh too much too much magic is happening hidden functions call in to Transformations exactly you hate the dollar sign dude people are too quit being quit being so hurt about the dollar sign it's not that big deal property hooks Provide support for uh computed properties that can uh natively be understood by idees and static analysis tools without needing to write doc block comments that might get out of sync okay I mean that's cool I just don't think I like it all right asymmetric visibility private string version A3 public get version this version increment okay class public private this looks stupid but honestly this is actually pretty cool oh that is cool yeah that is actually super cool the the ability to have properties but then be able to hide its setting behind a private is pretty great I actually like this super position variable that's cursed why is it cursed what makes this cursed come on land land of Le you're up on the big board what's cursed about it I expect an amazing breakdown of why this is cursed come on the keyword naming is what makes it cursed really that's it ah it doesn't bother me I don't think I it's saying hey it's public with a private set you can read it from left to right public left to right bada bing bada boom easy peasy pumpkin seedy no problem with it all right let's see the next thing deprecated attribute okay nice I like it deprecated 8. 3 use PHP version instead okay deprecated oh nice okay I don't know what these things are called but the this is like a special PHP thing that something happens right and I don't really know what it is I don't know what it is but I know that it exists it's an attribute I know but I don't know what it does I don't know how they work message use this instead since 8. 4 I mean this looks really nice it's better than a doc comment right we can all agree that a doc comments not great instead of having something that probably gives you more explicit exact you know exact versions and all that so that's that's pretty cool okay okay next let's see next or new extend Dom features in HTML 5 support all right new document load oh baby oh baby baby look at all of those things not even sure what to do with all of that HTML uh main is this like some sort of macro what is this uh main article article article HTML lib XML no err okay so this is the old version right all right new new version doc let's see Dom HTML doc create from string this okay query selector main last article see I don't really get this what am I looking at what am I even looking at here what I see the problem is I don't even know what they're doing right now right what is happening here okay so you're loading HTML versus creating it from a string okay okay okay you do some sort of X path node path Que the with crazy crazy amounts of CSS right not following sibling versus just this main article last child so it looks like you can use just query selectors so it's like you get the whole CSS selecting thing going on and then it's just dumping this in Array featured classes which is this okay oh oh I think I see it you're exploding class name so this is like some sort of this versus you actually get the node class name contains right is that is that a JavaScript feature is node class name contains a thing um document here uh body.
query selector right oh document. body right really is query selector not a thing yeah query selector right all right so yeah so if you do that let's see oh not query selector uh class class list uh contains okay so it's just okay okay so it's just remaking you get like you actually get class list contains okay so it's just a reflection of the Dom API oh okay so you're doing it feels confusing to me you're doing a bunch of HTML operations and hm I'm going have to think about that I gota be right back look who is causing trouble hey you yeah I swear I get a cat and they constantly cause trouble thank you hey Dylan thank you very much for that okay so this feature is just simply being able to have more accurate it's to have one to one API with the Dom right so that means I should be able to go like this document. create from is that is that is that is it like full because I don't know this one create from string so that's not one all right I was actually wondering if it could be like create from string if that was also one but it's somewhat more well somewhat like node class list this one is this one is definitely one for one cuz this looks horrible this looks much nicer like you get query selector you get this so then you can go here and you can grab the article's last child be able to GL okay that's pretty cool that's pretty cool it's for Zoomers who are familiar with JS I mean generally speaking I think that navigating an XML document via query selectors is pretty nice right like this this is nice this is a good feature yeah X paath query was really complicated yes this is really this is not fun this is pretty easy to understand all right object API for BC math I'm not sure what that means is before Christ math was math different in the old days versus versus today I guess they use like Roman numerals or some that's crazy back then okay so let's see uh we get a decimal we get a number two we do a little BC ad not really sure what you what we're doing here I'm not I I honestly don't know what that five is I honestly have no idea what that five is now we knew a number what is this Javas okay so this one I don't know what this means can I be real here for a second okay so it's it's just a floating point of five okay by the way if you're doing an example PHP 4 if you're listening if you're listening PHP if you're doing an example especially for us laymen who are not uh as well understanding of all these things definitely do something that's like maybe truncates it if you would have put a four here and then truncated it I would have been like gotcha information's below you know we don't read okay what do you think what do you think we're doing here you think we're reading you think this is a reading stream I don't know if this is for me read I Just Vibe check yeah this is a Vibe check stream okay we're just Vibe checking real hard right now by the way this is just straight I mean I guess I don't understand this feature is this like a normal feature people use honestly I'm so used to this I bet dude I cannot tell you how many times I've done this like Precision right uh numb and then uh P right and then just be like return math.
uh math. floor and then just do uh number times Precision divided by Precision you know how many times I've done like that that guy like that thing has just like just just just one, times in my brain I have programmed this dumb this dumb thing over and over again so I guess PHP they just have it built in well that's pretty cool it's basic calculator interface oh it doesn't stand for for before Christ okay yeah that makes sense that actually makes way more sense basic calculator than the other one okay okay I see it I I I get it these objects are immutable let's see okay new array functions oh new array functions let's go for each dog cat value as value do this okay array find static function bull string starts with oh beautiful let's go what a great day nice little filter function oh that's cool I didn't realize that you can also do these little floating these closures it'd be nice to maybe have a a touch more supported Syntax for this so you don't have to write that much that much code just to do the exact same thing a nice Arrow function here would be great a nice little Lambda function of some sort would be fantastic but why declare static because anytime you do these things they're often declared static whenever you create a function where do you think that function goes right you can admit the static I assume the static is a performance thing right is that this function does not have any closure it doesn't need anything it is its own tippity top right I I that's just how I that's how I read this now I could be complete I could be completely wrong on this it doesn't B the yeah okay does a static doesn't carry context okay so I'm not crazy yeah but it's really microseconds oh absolutely you're absolutely right it's definitely like it's an you're using PHP which probably probably to be completely fair means that your like performance of static versus like non-bound versus like lexically bound scoping functions is probably not where like you probably don't care that much can we be real here can we be real right so you got array find array and F key array any ARR all oh nice okay nice that's sum and every cool cool so I assume array do or array any is just uh sum it's the equivalent of sum yeah check at least one array element nice nice very cool good job PHP PDO driver specific sub classes okay so this is just fun times nice oh nice we got squeal light let's go good example good answer good answer okay let's try to see the difference between them connect create function I really can't tell the difference between these two oh okay oh I see this I see this okay so it's not a generalized interface anymore it's actually oh nice okay I'm stupid I'm sorry create sque you have to do squeal light create oh okay so that means the connection beforehand used you you'd have to do like post addess create stored procedure right you'd have to do some sort of like you'd have to do like they were all there and thus you had to go through everything now it's like a unified interface where it's just like create function bada bing bada boom let's go okay that's sweet that's sweet that's sweet again I love I PHP is just doing all the right things I swear they're doing all sorts of great things here okay let's look at this class function return wait what new class method without parenthesis oh nice okay better parser let's go you have to do a new class right here and you have to cover it so that way you get the return okay yeah yeah yeah yeah yeah yeah pre order precedency this this had a higher this had a higher precedence than new thus new wouldn't be executed on PHP I love it great great PHP is getting better all the time PHP is getting better all the time these array functions like way to catch like way to catch up to to most I mean they're they're they definitely have a lot of catch up to do I like this I think this is all great this is all fantastic I'm actually excited to do a PHP website coming up here soon hopefully I think I'm just nailing down the dates right now because I'm having let's just I'm I'm going to tease you guys a little bit let's just say that we're having two people fly in and we're going to stay at the compound and help me make this happen Okay that's all I'm going to say we're not it's all I'm going to say say you know I'm not going to say anything else I'm very excited for this I'm very excited for this this is so good okay awesome I love seeing this I can't wait to use PHP 8.