If people are having issues around 1:03:00 he solves the problem right around 1:10:40 so don't lose hope! Thanks for the great video, I'm learning a lot!!
@johnnyw.s.23723 жыл бұрын
Thank you... I'm trying to figure out what is being done in this part and going to give up until see you comment...
@gutofguts Жыл бұрын
What a CHAD
@ThiagoAlves-if3rl2 жыл бұрын
I'm Brazillian and even I not speaking english very well, your explanation was the best that I have seen. And all I have to say is thank you for sharing this for free, you are awesome.
@chinonsoikewelugo54862 жыл бұрын
I can't thank you enough for this. Went through the whole 6 hours and now I have my own functional PHP framework, and was able to learn a lot of new concepts I had previously overlooked. This is handsdown the best tutrorial I've come across!
@TheCodeholic2 жыл бұрын
Thanks a lot
@francisokoroafor2023 Жыл бұрын
how fa
@howuseehim Жыл бұрын
He said don't use it
@ThaiBinh-A7 ай бұрын
I am Vietnamese and I have been researching MVC for my first project. This information is exactly what I needed. Thank you very much.
@alexandergarcia-yo6kw3 жыл бұрын
i'm new in php, i just made mike's tutorial, now i'm at 2 hour of this tutorial, it is awesome what i has been learn with this, it take me 3 days to watch this 2 hours but it's totally worth
@MatiasAE_179 ай бұрын
I watched until the 17th minute, but what can I say? Just wanted to say thank you!!!!!. It really encourages viewers to read and investigate more about the topics. Again, thank you!
@waynekille49144 жыл бұрын
This is superb. Fast paced & does exactly what it says on the tin. Thank you very much for creating and sharing this for free, it is absolutely invaluable and you are very generous!
@TheCodeholic4 жыл бұрын
Thanks buddy. Appreciate your comment.
@vusimdudu90333 жыл бұрын
This is the best tutorial I have watched on MVC, as well as being excellent on allowing me to understand how frameworks work.Well done.
@AmitDas-yb3re4 жыл бұрын
It is such an awesome series, you will learn many things on the way. This series will start your intermediate phase from beginners. The code quality is awesome. From last year I did a couple of MVC frameworks but none is comparable to this series. I am eagerly waiting for the Laravel series with an e-commerce project. Make it a paid course I will happily buy.
@birukindrias43083 жыл бұрын
can any one help me please with the migration Class 'm0001_initial' not found in C:\Users\hp\Desktop\mvx\core\Database.php:33
@danuzonez Жыл бұрын
Best PHP Framework tutorial. Want more videos like this.
@alexanderkucheryuk47224 жыл бұрын
This is excellent! Programming is a hands-on experience. By building your own mini MVC framework you get to grasp how larger frameworks (e.g. Symfony or Laravel) work.
@rezwanhossainsajeeb644 жыл бұрын
I'm from Bangladesh. I am a native of Bengali. That's why I'm not well at English. But I enjoy this tutorial... A lot of love for You.
@monsurrahmanriaz51573 жыл бұрын
bro, I'm from bd. ai course kemon? ami suru korte casci.
@smhaseeb4 жыл бұрын
I just learned python and now i want to become an expert. This channel helped alot.
@swooshkid95934 жыл бұрын
this is php bro
@smhaseeb4 жыл бұрын
@@swooshkid9593 I said channel, not video
@PankajSingh-hz2gr4 жыл бұрын
@@smhaseeb 😂
@nemac232 жыл бұрын
@2:08:00 Another option is to use heredoc instead of sprintf. I think it's easier and more legible. That goes for the sql statements using backticks too. $label = $this->model->labels()[$this->attribute] ?? $this->attribute; $error = $this->model->getFirstError($this->attribute); $input = $this->renderInput(); return
@fajar3123 жыл бұрын
Thank you for making it in one complete video, warm greetings from Indonesian developers
@yulianloaizaАй бұрын
What a great tutorial! Thanks for the detailed explanations of why you do what you do. I will most definitely check your channel and the content you create!
@nikakhutsurauli46473 жыл бұрын
Hello Zura! Glad to see you here too
@lolgamer42652 жыл бұрын
At 2:52:42 if you can't instantiate migration class...this should work in PHP 8.1: className = pathinfo($migration, PATHINFO_FILENAME); $class = "app\migrations\\" . $className; $instance = new $class; echo "Applying migration $migration ..." . PHP_EOL; $instance->up(); echo "Applied migration $migration" . PHP_EOL; //Basiclly we have to append the namespace to the classname so when we create object, the object knows from which namespace should be created.
@learntoswim512 Жыл бұрын
I have having issues with this exact problem. I tried you solution but get told, "Cannot declare class m0001_initial, because the name is already in use". Any suggestions?
@gametroll63112 жыл бұрын
I so appreciate you for this. I've always wanted to learn what it takes to create these frameworks. Your lesson here is hands down the best I've seen. Very informative, very thorough, I love that you even go to great lengths to explain every detail from the what and the why to the how it is done. I can't thank you enough. Perhaps some day, if you haven't already done it, you'll do one of these videos on creating a javascript framework like React, Vue, and Angular?!?!
@thestorytimecrew9 ай бұрын
I am very happy too see dear zura .... and u teach new leasson and new journy.... also the best work you and freecodecamp organization.... keep it up this is the best work for all students and other developer .... whaterver people think but my thinking is ..zura and freecodecamp given jobs and gets blessings of people
@minguinmyoui77864 жыл бұрын
this is what i'm waiting for ~Thanks
@TheCodeholic4 жыл бұрын
Glad to hear that
@BillClinton2284 жыл бұрын
Fantastic course... thank you so much for putting this on youtube.
@TheCodeholic4 жыл бұрын
Thank you too
@rakinar22 жыл бұрын
By watching this video course, I built my own MVC framework, 'Invention Framework'. Thank you Zura; loved this course.
@nilambarsharma48698 ай бұрын
Nice tutorial.
@BucurIonNiculae4 жыл бұрын
Thanks for this video tutorial, greetings from Romania.
@TheCodeholic4 жыл бұрын
It's my pleasure
@swooshkid95933 жыл бұрын
1:57:44 this wouldnt work in php 8 with strict types on since str_replace expects a string|array and not an integer at the second parameter. An easy Fix would be to cast the value into a string with the php built in function strval()"
@leodesiatnykov40314 жыл бұрын
You are a star! Unbeatable skills+++++
@TheCodeholic4 жыл бұрын
Huge thanks
@ilya_123__10 ай бұрын
thank you Zura!!! it is difficult for me, but i keep trying to understand. sorry for my bad English. you work is great!
@charlesthomas86119 ай бұрын
This man is purely professor in this language
@phucthaifg3 жыл бұрын
omg, you are so talented! Thanks for the sharing!
@noxdralock62934 жыл бұрын
Thanks a lot for this very good video ! I learned a lot during this course, I already worked with Symfony and it allowed me to have a better understanding behind those frameworks ! Keep up the good work 😉💪
@charbelabouyounes66833 жыл бұрын
Thank you so much for this tutorial it is really awesome. If possible could you answer this question? How did you learn all of this, is it over the years or is there some kind of documentation that you used. And how would you advise people when trying to improve their php knowledge
@benjaminspinola1788 Жыл бұрын
nice curtains. But other than that: Awesome tutorial! :)
@djolemc14 жыл бұрын
At 1:08:50, why don't you use extract($params) instead of foreach(...) ?
@mcg6429 Жыл бұрын
Thanks for the video, this is the best tutorial of PHP
@ნოდარდავითულიანი2 жыл бұрын
Wow, didn't expect that. He is from Georgia, really underrated country 🇬🇪
@emadesavi80159 ай бұрын
God bless you, this video is great, I learned a lot.❤🙏
@muhammadasifch39263 жыл бұрын
It is really amazing, useful and learnable video. Thanks dear.
@AndreSilva-gb2hj3 жыл бұрын
Thanks for the awesome course!
@nielsvansteen90873 жыл бұрын
Although a great tutorial for learning how to build a framework with PHP, there are some (in my opinion: major) concerns about your approach with OOP programming, like for example around 04:43:58 when you make a class 'BaseMiddelware.php' that class is abstract and only has 1 abstract method, so why don't use an interface? This was also no the first time, somewhere in the video you could also use an interface instead of a class. And secondly, almost all your properties are public, and yes I understand with PHP being a dynamically typed language it is easy, to store the variables in a string array and dynamically get/set the value like that, you could still make the properties private (or at least protected) and use 1 global setter/getter per class and pass the name of the property as an extra parameter and get or set the value like that. and last, although this might be subjective, your classes have very high coupling between them, which could probably also be improved. EDIT: I just want to say, even though I 'criticized' the OOP way, I still enjoyed this video, and would recommend it, I learned a lot. And tbh if you want to make a framework you should know enough about programming that you can improve the OOP aspects yourself if you want to.
@adipurnomo56833 жыл бұрын
So MVC method was found in 90's, isn't it?
@floringanea69443 жыл бұрын
Very good my friend! danke shanke!
@thecodeluminary3 жыл бұрын
Please can you do a tutorial on how to host this on cPanel: I'm having issues hosting it
@dAvid3_f3 жыл бұрын
Awesome tutorial, thumps up to the author !
@alexandergarcia-yo6kw3 жыл бұрын
Solution to " Uncaught TypeError: call_user_func(): Argument #1 ($callback) must be a valid callback, non-static method app\controllers\SiteController::contact() cannot be called statically" error during the implementation of the controller hello, i'm using php 8.x, i solved this problem making static every function in SiteController (where i had to use SiteController), based on the documentation in the version 8.x the operator :: is used for static functions, i also had to use use app\core\Application in the SiteController to include Application in SiteController. I write down this here just in the case other one had the same problem. (sorry for my english, I'm not a native speaker)
@RebrandSoon00003 жыл бұрын
Thanks! Ran into this issue and now you solved it, thank you.
@jaimeponce29683 жыл бұрын
This is another solution: If a SiteController instance is passed then run public method normally. $app->router->post("/contact", [new SiteController, 'handleContact']); posdata: I'm not a native speaker either xd.
@komellar973 жыл бұрын
Thanks for the solution of the problem
@efqanmesediyev59793 жыл бұрын
Thanks you
@VincenzoCorvaglia2 жыл бұрын
Very useful information. Tank you.
@Ab-cj6gl3 жыл бұрын
This guy is a legend
@DucMinhTeaching3 жыл бұрын
how do you set up PHP to avoid "not found" at 8:52. I am using MAMP
@cptnstark33503 жыл бұрын
The server needs to be configured to route all requests to the index.php. To do this create a file called ".htaccess" and use the Rewrite commands. The solution is outlined on stack overflow when you search for: redirect-all-to-index-php-using-htaccess
@Arlasdarier3 жыл бұрын
thanx for the fantastic course!
@alexbayarov30722 жыл бұрын
2:00:01 - no navbar, 2:00:48 navbar appeared. Why?
@DucMinhTeaching3 жыл бұрын
If you have this error: Deprecated: call_user_func() expects parameter 1 to be a valid callback, non-static method app\controllers\SiteController::handleContact() should not be called statically in /Applications/MAMP/htdocs/MVC/core/Router.php in 1:04:00 just add static to to handleContact() namespace app\controllers; class SiteController { static public function handleContact() { return "handle the contact"; } }
@DucMinhTeaching3 жыл бұрын
However, you cannot use $this inside static so in index.php should change into this $siteController = new SiteController(); $app->router->get('/',[$siteController,"home"]);
@TheLittleMaestro29114 жыл бұрын
good luck for your channel...
@TheCodeholic4 жыл бұрын
Thanks
@mahendranath25044 жыл бұрын
A Big Thanks to you, and for your effort. I know working on core PHP is more helpful to understand things well, I appreciate your effort, this video will help us to understand or learn PHP a lot well, a happy subscriber, i subscribe to your channel as well thanks for amazing content
@TheCodeholic4 жыл бұрын
Thanks buddy.
@ahmadzreqat23764 жыл бұрын
I like your framework is combines laravel and yii2 frameworks Greet job
@joppieb92373 жыл бұрын
Hello thanks for the great tutorial about MVC. I have an error around 1:03:00 Fatal error: Uncaught Error: Class 'app\controllers\Application' not found in /Applications/MAMP/htdocs/framework/app/controllers/SiteController.php:15 Stack trace: #0 [internal function] are they more people with this error?
@Fmly-gyd043 жыл бұрын
i have the same error
@nemac232 жыл бұрын
use app\core\Application
@lashakajaia10793 жыл бұрын
მადლობა ზურა ! ❤️
@ebubabangida4 ай бұрын
thank you bro form ET.
@rudinandrey3 жыл бұрын
very well begin of tutorial, I will watch all this video, thanks a lot. I think it is very helpfull
@SuperDaroG3 жыл бұрын
1:08:33 - Wasn't it better to use an "extract" function rather than a foreach loop?
@randylhopkins38362 жыл бұрын
Howdy, really like your methods and php mvc framework. I'm stuck at 3:59 Login, everything have worked until the Login setup which error at DBModel line 40, Error: Non-static method app\models\User::tableName() cannot be called statically in /var/www/html/phpmvc-framework/core/DbModel.php on line 40.. Can't seam to fix this error. Any ideas? The line code is: $tableName = static::tableName(); Thank you!
@joel-rg8xm2 жыл бұрын
Those methods have to be created as static, I figured it out by the GitHub code :)
@dawnpeace91224 жыл бұрын
simply amazing
@DevsLikeUs4 жыл бұрын
Love this !
@TheCodeholic4 жыл бұрын
Thanks
@emmanuelmnzava89663 жыл бұрын
Really thank you for this.
@supersquat Жыл бұрын
@ 5:45:22 I'm getting an error: Root package '' cannot require itself in its composer.json Does someone know how to fix this?
@mohammadjabedhosen96803 жыл бұрын
Really awesome
@Edi_LifeStyle3 жыл бұрын
Thanks a lot for this very good video. What font and theme did you use in your text editor in this video?
@lahcenaouina Жыл бұрын
Thank u so much
@sumitmakwana59153 жыл бұрын
hi there, can you make a separate video on how to make own custom ORM like Eloquent in laravel ?
@fatafatrecipe94474 жыл бұрын
You are amazing thank you 👍
@TheCodeholic4 жыл бұрын
Thanks a lot
@technotv32274 жыл бұрын
well its 12 in the night, and look what i am watching >
@TheCodeholic4 жыл бұрын
lol 😀
@heftig.76143 жыл бұрын
2 am here in germany now, guess what iam doing? xoxo
@tigidou33443 жыл бұрын
Sanitize off front all request input is a bad idea when multi system access the DB. Because, you MUST sanitize exatly with the same process. Example : login with password. If you hash the password after sanitize, the hash maybe not be the same with an other sanitize process.
@alvin_lal3 жыл бұрын
thanks , very helpful !
@fajar3123 жыл бұрын
When we define a route in the form of, we cannot access the '1' or 'slug' parameter other than using the $ _GET global. We send Request and Response classes as parameters to the controller. Likewise how can we send this '1' or 'slug' parameter ?
@InverserPro2 жыл бұрын
Thank You so much!
@tofudimsum80723 жыл бұрын
As you said, it is not production ready. But what constitute as "production-ready"?
@Personal-M.I.S.2 жыл бұрын
I know this is a bit old right now and though still a ton of good info, but what would be really cool is if you did another video using a TDD approach =)
@variouseducatoinaltube64234 жыл бұрын
That's awesome!
@webservicege35873 жыл бұрын
Thank you! :)
@DucMinhTeaching3 жыл бұрын
wait a minute, where is your "contact" folder at 36:00???
@borisbar41482 жыл бұрын
What I don’t understand is why I’d need the renderView and renderViewOnly functions also inside the Router class. From the Controller class you could simply refer to the View class directly. Why the detour?
@pareshdawda8854 Жыл бұрын
Hi Zura, Thank you for sharing this great tutorial. I am learning to implement my code better. I have a request and am hoping you can help me (and others). I need to implement cascading dropdown selects within the confines of the MVC framework. Can you please advise how this can be done.
@JACKoPL4 жыл бұрын
Good job for learn. Few month searching of this. I know it's small, project and use to teaching. It's not laravel but better for db its use illuminate\database, I think. Routing better separating to other file/s. Maybe you say of this. My english is poor ;)
@DucMinhTeaching3 жыл бұрын
Hi, can anyone explain SiteController :: class in 1:03:07 ?? Thank you
@youtuberjonyo60943 жыл бұрын
Thank you very much for your kind contribution to us. How can include my css and js file locally into my layout view file? Please, help me with that.
@wibowomuhmmad4 жыл бұрын
Yesss finally
@rockybalboa56003 жыл бұрын
Video is nice. I reached at 1:30:00 where a separate layout for login and registration is created. But the Not found is not working over there it gives error. Please help
@nemac232 жыл бұрын
What error?
@medazizyahyaoui66122 жыл бұрын
Hello friends I need help with this issue "PHissuel error: Uncaught Error: Class 'm001_initial' not found " at 2:51:59 and thanks advance.
@lolgamer42652 жыл бұрын
At 2:52:42 if you can't instantiate migration class...this should work in PHP 8.1: className = pathinfo($migration, PATHINFO_FILENAME); $class = "app\migrations\\" . $className; $instance = new $class; echo "Applying migration $migration ..." . PHP_EOL; $instance->up(); echo "Applied migration $migration" . PHP_EOL;
@medazizyahyaoui66122 жыл бұрын
@@lolgamer4265 thanks dude it's work
@lolgamer42652 жыл бұрын
@@medazizyahyaoui6612 Niceee..
@jeremymattausch221810 ай бұрын
Hey guys. First of all, probably still one of the best PHP lessons I've seen so far. I just have a couple errors I can't seem to be able to fix. Would anybody be able to help me ? I just finished implementing the "Hide Login/Register buttons" and in the Application class, in the static function isGuest(), apparently the "user" must not be accessed before initialization. Would you be able to tell why that is ?
@ahmedwali45482 жыл бұрын
excellent
@zunpaingyellhtun98864 жыл бұрын
thanks a lot :) for this video
@TigranKuchatyan Жыл бұрын
Do we need really to initialize object Request in 2 places? I get same result only having initialized it in Router class.
@borisbar41482 жыл бұрын
I’m stuck at around 1:00:00: The renderView($view) function returns NULL for both var_dump($layoutContent) and var_dump($viewContent). I have a blank web page. Has this something to do with the ob_start() and ob_get_clean() functions? When I remove them I can see the layout and the page but without the {{content}} string being replaced. output_buffering is set to 4096. Please help.
@borisbar41482 жыл бұрын
I was able to get rid of the problem: What I missed was putting a return in front of each ob_get_clean() function. Now it works like a charm!
@fatihkara64112 жыл бұрын
Will be subtitle this video ? English or auto translate
@ScottyDub-E-U2 жыл бұрын
What PHP extensions do you use to create a new PHP file? Thanks!
@michaelgrigoryan25__old4 жыл бұрын
You should create a tutorial on how to create JS MVC framework. Would be really, really, really,really dope
@rimantasdanilevicius67544 жыл бұрын
let me know if you will find such tutorial :)
@0xDEAD_Inside4 жыл бұрын
These might help: kzbin.info/www/bejne/jmHVooOch8t4nLc kzbin.info/www/bejne/a5fNk61mYteFaLc kzbin.info/www/bejne/aGWqd2iDi6p4oKc
@vainglories75123 жыл бұрын
No
@raffimansoor37394 жыл бұрын
You are awesome..I admired a lot about your videos..I ha ve one suggestion ..can you please do a Xamarin Forms full course ?
@TheCodeholic4 жыл бұрын
Thanks. Unfortunately I don't have any experience on Xamarin.
@KJ_Yuugen3 жыл бұрын
hi i got an error at 1:02:41 is does not pass the array is say "Fatal error: Uncaught TypeError: call_user_func(): Argument #1 ($callback) must be a valid callback, non-static method app\controllers\SiteController::handleContact() cannot be called statically"
@buhahemal46353 жыл бұрын
pass the class object
@lawrencejohn16383 жыл бұрын
follow on with the tutorial he solved it minutes later
@astrolillo2 жыл бұрын
You can make your functions static in the Controller class or instead of passing the class you create an instance like this: $app->router->get('/', [new SiteController(), 'home']);, this is assuming you are using PHP 8.1+
@maherkhalil0074 ай бұрын
do you have a course like this but with python?
@tanjirmahabub51053 жыл бұрын
Nice tutorial. How to run this project from xampp without running server?
@hellobraundesign2 жыл бұрын
1 000 000$ Man! Thx
@simonedagostino87603 жыл бұрын
Hello. If I have two different tables in the database (users and complete_profile), how do I insert the values sent by the registration into both tables?