Thank you for watching! Please consider supporting my channel: ☕ko-fi.com/davehollingworth
@ahmad-mureryАй бұрын
Even though I already know how PSR4 and spl_autoload_register work, I still found this video is very well organized and easy to follow. Thanks Dave!
@ianw9349Ай бұрын
Many thanks, Dave. Your videos are always so clear. A great pleasure to learn from you.
@MemoryMireАй бұрын
You can be a high paid influencer with this chill voice and clear accent. I wish to see a detailed Laravel course from your voice and significant teaching skills.
@pythonantole9892Ай бұрын
This was so helpful. I have learned alot and now understand the namespace declarations and use statements in frameworks like CI4 (learning CodeIgniter 4 from your course.)
@joel-rg8xmАй бұрын
Thanks for such a clear explanation
@sam-j4zyАй бұрын
This is great, thanks alot for sharing sir.
@ploob115 күн бұрын
The Hivemind Has Found It's Next Victim
@NedumEzeАй бұрын
Dave, thanks so much. The best handling of this topic ever. Never seen anything near as good. I need your help. A question please. Too often I am forced reinstall Composer! Is that your experience? I install it globally. And in days, when I need it in another Project, I get the crazy message "command not found"! What am I doing wrong. I run on Windows and Wampserver
@dave-hollingworthАй бұрын
Thank you for your kind words! I've never experienced that I'm afraid. It could be a Windows thing - I have experienced Windows uninstalling programs before. I did a quick search and can't find any references to this problem. Maybe install it as administrator?
@NedumEzeАй бұрын
@dave-hollingworth I did install it the last time as Administrator. Thanks for all your selfless help
@dave-hollingworthАй бұрын
@@NedumEze Try installing it locally to each project, see if that makes a difference (i.e. composer.phar is inside your project folder)
@NedumEzeАй бұрын
@dave-hollingworth Oh! Okay. I will try it out. Maybe the answer. Global installation has been a pain. Does NOT PERSIST for me. Thank you very much, Dave
@dmxdАй бұрын
Dave, what code editor and the theme/color scheme you use in this video?
@dave-hollingworthАй бұрын
Visual Studio Code, and this theme: www.vscolors.com/themes/bf8aa94a-4051-42fe-9bd1-2becad466fe7-41e84e99
@3minutes.officialАй бұрын
Thank youuuuu 😍😍😍😍 am understand OOP and create class sample and route path we give more sample course OOP 🎉🎉🎉❤❤❤❤❤❤❤❤❤❤❤❤❤❤❤❤❤❤❤❤❤❤❤❤❤❤❤❤❤❤❤❤❤ keep up 👍🏻👍🏻👍🏻👍🏻👍🏻👍🏻👍🏻👍🏻
@abdelhamidnehlil727727 күн бұрын
merci
@MobiusCoinАй бұрын
What makes the spl_autoload_register() special? Why can't just write what is equivalent to its callback function and just use that?
@dave-hollingworthАй бұрын
I'm not sure what you mean, but spl_autoload_register registers a function that is called automatically when the PHP interpreter doesn't find a class that's being used. It gives the code a chance to load it before a "class not found" error occurs.
@MobiusCoinАй бұрын
@@dave-hollingworth I guess what I mean is why can't I do this: function load_scripts($class) { require $class . '.php'; } load_scripts('app'); at the beginning of the file?
@dave-hollingworthАй бұрын
@@MobiusCoin You could, but that function wouldn't be called automatically if a class wasn't found, you'd still have to explicitly load them. With spl_autoload_register, when PHP comes across a class that hasn't been defined yet, e.g. $user = new User; if there is an autoload function this will be called. Inside the autoload function you can require the class, then the PHP interpreter goes back to where it was when it came across the class.
@MobiusCoinАй бұрын
@@dave-hollingworth ahh got it, thanks
@jediampmАй бұрын
Hi Mr.Dave, thanks for the video. Also is missing the info that composer also is capable of load files, which can have functions or constants. Also to be a complete / detail about autoload with composer, mention about classmap and psr-0. Thanks anyway.
@rustamergashev7278Ай бұрын
👍
@rafanarafanaАй бұрын
Hi, Dave. Can you add a polish soundtrack? Many people from Poland are watching you. Thank you for your tutorials.
@dave-hollingworthАй бұрын
The alternative languages are added automatically by KZbin. I'll see if there's an option for a Polish one.
@tanzimibthesam586125 күн бұрын
I dont know why you didnt include autoload in your MVC course
@dave-hollingworth24 күн бұрын
I do have a plan to include it, when I eventually get around to it!
@3minutes.officialАй бұрын
😅 my English very sample am learning languages 🤦🏻🤣 thank you 🎉🎉❤❤❤
@WizatekАй бұрын
I am not a fan of namespaces in PHP, i never use them
@Mr.Jacks-s5qАй бұрын
Please, if you make the audio track in your video Bengali, it would be beneficial for us Bangladeshis or those who follow you from my Bangladesh country. Please please bangla the audio track. ☺☺
@dave-hollingworthАй бұрын
I'd love to help, and I'll look into it, but I doubt I'll have time right now - if you provide the audio track in Bengali though I'd be happy to upload it to the video