What is programming MVC? [Detailed Explanation]

Поделиться
HTML-код
  • Опубликовано: 27 янв 2025

Комментарии • 587

  • @Pendragon2879
    @Pendragon2879 2 года назад +14

    Came here for 100Devs and this is a solid explanation! Thank you for this!

  • @helloimsick5587
    @helloimsick5587 6 лет назад +9

    5:00 starts explaining web (recommended for beginners)
    15:50 starts explaing mvc (here it begin)
    19:00 quick recap
    i would still recommend beginning at 0:00 for the sake of great effort what is here made .
    Thanks you very much for the explaination devMarketer!

    • @CodeguruX
      @CodeguruX 2 года назад

      Yeah, it's a bit confusing when the recap adds route processing and has the view interacting with the user before the controller actually receives the dynamically processed view response. Kinda like saying it goes to all the trouble of finding the correct controller to just toss it out of the equation after the view is hit with a request. It's a stupidly simple concept though, so it doesn't really matter. The only thing to remember seems to be User->Controller->Model->Controller->View->Controller->User. Basic "pipeline" or "black box" architecture that allows things to interact in a way that gives you less and less job security the better it's implemented. But luckily you're always working to impress the next guy that pays you more money to do a thing and gaining practical knowledge along the way to make sure there's an ample supply of those.

  • @ajassharafudeen
    @ajassharafudeen 7 месяцев назад +1

    This video is part of 100devs course and I understood every bit of information explained in this video. Thank you very much.

  • @NathanBudd
    @NathanBudd 6 лет назад +26

    I've watched a lot of videos and tutorials, and read a lot of resources online.
    This is the best explanation of MVC that I've come across.
    *subscribed*

    • @rickyanthony3900
      @rickyanthony3900 3 года назад

      I guess Im randomly asking but does someone know of a tool to get back into an Instagram account..?
      I was dumb forgot my login password. I would love any assistance you can offer me

  • @chintanraval2928
    @chintanraval2928 7 лет назад

    Jacurtis(C) you are the controller who have all variables to explain and enhancing the viewer(V) with best data information (M). Thanks alot for the tutorial.

  • @jays
    @jays Год назад

    7 years later, still a great resource. Thank you!

  • @gregb2225
    @gregb2225 7 лет назад

    By far the best MVC tutorial I've ever seen. No longer confused!

  • @tauqeer1036
    @tauqeer1036 2 года назад +12

    Coming from #100Devs. This was a fab intro for someone who just heard of MVC.

    • @JD-hq1kn
      @JD-hq1kn Год назад

      I'm sure you're building awesome apps by now. I'm currently on the MVC class.

    • @ralphalmonte7042
      @ralphalmonte7042 8 месяцев назад +1

      niceeeeee

  • @ayoubakennaf6388
    @ayoubakennaf6388 5 лет назад +1

    This is awesome ,
    I'm a data scientist engineering student and i'm developing a web application and this video helped me , I now have an idea about the MVC and i'm willing to go deep ,
    anyway i would love to thank you for your efforts, you're doing a great job , keep up.

  • @amarenigatu7464
    @amarenigatu7464 7 лет назад

    Finally i got what the hell it is ...MVC!!! Really you make it easy and very clear. Thanks a lot!!! keep going

  • @mostafaomar5441
    @mostafaomar5441 5 лет назад +3

    Note for others on what he said at 16:30. I was really confused by this as I found in some other explanations that the model can communicate with the view directly.
    MVC can be implemented in many ways. One of them is where the model communicates with the view directly. Is it the neatest way? I don't know.
    So, don't get confused when you find different explanations for the MVC. For example, some will call it a design pattern, others will call it an architectural style. It all depends on the context you're using it.

  • @shanemccurdy
    @shanemccurdy 7 лет назад +2

    FINALLY! Someone walked us through MVC thoughtfully. This should be the first video that comes up when you search for MVC on RUclips! It makes sense now, thank you!

  • @guilhermelaviola8079
    @guilhermelaviola8079 5 лет назад +3

    That's one of the best Web Development classes I ever watched! It made me understand how MVC works in less than 20 minutes! Awesome! Thank you @jacurtis !

  • @CourageousCreatives
    @CourageousCreatives 4 года назад

    Our Coding Bootcamp gave a link for this explanation of MVC before we have a unit on it. Great run-down!

  • @colonelvector
    @colonelvector 6 лет назад

    Thank you for this, this is the only video I've seen which properly explains MVC

  • @theHelenZhang
    @theHelenZhang 2 года назад +1

    This was so helpful! When I say I am new to client-server and MVC architecture, I mean it. This video broadly touches on how the model, controller, and view work with each other. It doesn't go too indepth with the specific programming and details of them, which makes this concept easier to understand. This video for sure helped me understand how MVC architecture works with the client-server-database flow. You explained easily, and I had no trouble understanding it. Thank you!!

  • @GavinAyling
    @GavinAyling 7 лет назад

    This video was recommended by my university lecturer! Good work DevMarketer.

  • @mdneyamatullah8449
    @mdneyamatullah8449 7 лет назад

    Best MVC tutorial I have ever seen before !!!! Thanks Jacurtis.

  • @xeroks646
    @xeroks646 7 лет назад

    I rarely like or comment on a youtube video but this video is an exception. I watched over more than tens of MVC videos and I never understand them but after I watched this I really understand WHAT THE HELL IS MVC lol. Really thanks man I appreciate your simple explanation. Now I can do my own framework in peace :)

  • @arechigaartstudio
    @arechigaartstudio 8 месяцев назад

    Your teaching really helped me understand quickly what MVC means in programming. Thank you for sharing your knowledge with all of us!

  • @isaacopoku-asare5362
    @isaacopoku-asare5362 7 лет назад

    Woooow. that was so simple. MVC seemed confusing until after your video. Thanks Jacurtis

  • @canmetan670
    @canmetan670 7 лет назад +293

    Skip to 5:30 for the tutorial........ yikes.

    •  6 лет назад +12

      I'm 13 minutes in, and he still haven't really started yet... He's just talking about web servers and databases and programming languages. Nothing yet that helps me understand MVC at all.

    • @stermister123
      @stermister123 6 лет назад +15

      pro tip: speed at x1.25 or x1.5

    • @desirocker9099
      @desirocker9099 6 лет назад +1

      a saviour

    • @kurchak
      @kurchak 6 лет назад +7

      Thank you! What a waste of fucking time.

    • @alx_z1
      @alx_z1 5 лет назад

      true hero!

  • @arpitagrawal8530
    @arpitagrawal8530 Год назад

    An example of genuine teaching

  • @HEROHODA5000
    @HEROHODA5000 7 лет назад

    This without a doubt The Best Explanation of MVC I've ever seen,
    Thanks very much.

  • @ignacio560
    @ignacio560 6 лет назад

    Excellent video. I'm sorry for all the hateful comments, clearly people have misled expectations on educational content. This was awesome, very clear. Thanks

  • @makgatoselaelo
    @makgatoselaelo 4 года назад

    I Finally understand a simple pattern called MVC that I used on daily basis as a user to send requests to the web browser and not knowing what was happening in the background. I never questioned myself how the processing was occurring. MVC implements OO concept called Encapsulation. Yes South Africa

  • @Grenbestyie
    @Grenbestyie 5 лет назад +4

    Your video said the model never talks to the view and the view never talks to the model. That does not fit the standard MVC UML diagram logic. It is more akin to the 3-tier architecture. I think the view does talk to the model when instructed to do so by the controller. [Happy to be corrected in my thought, as I am still learning]

    • @zhrxxo6610
      @zhrxxo6610 4 года назад +1

      genuine question tho, why would the view talk to the model directly, if anything it needs to go thru the controller in terms of networking isnt it - ?

  • @jenso413
    @jenso413 2 года назад

    I think it's great that you also explained how a website works, it's integral to understanding MVC!

  • @miguelpunzal3028
    @miguelpunzal3028 7 лет назад

    The best 25 minutes of my life.

  • @jasper4803
    @jasper4803 6 лет назад

    No one can explain MVC better than you did

  • @heyamjoe
    @heyamjoe 3 года назад

    NoSQL is a type of database and MongoDB is an example of a NoSQL database. So, technically, NoSQL is an architecture while MongoDB is an implimentation.

  • @vidaltrejo5493
    @vidaltrejo5493 2 года назад

    Best explanation i found on youtube

  • @MarcMcRae
    @MarcMcRae 5 лет назад

    IMHO the under-pinning (additional) info can't hurt to show architecture/components etc. Nice video!

  • @vendrim1962
    @vendrim1962 4 года назад

    This is great information. Seriously
    This will save you massive amounts of tutorial time.

  • @mohammadanas3047
    @mohammadanas3047 4 года назад +1

    This was my first dig at MVC and the video made it so simple to understand!

  • @muhammadk5935
    @muhammadk5935 7 лет назад

    very useful, finally understand mvc. i read about it before and it was useless. very clear, descriptive easy to understand.

  • @57Sauce
    @57Sauce 8 месяцев назад

    Here from 100Devs. Great video, thank you!

  • @Raptor-jv7fi
    @Raptor-jv7fi 7 лет назад

    Hats off to you man! Finally I understand how mvc works...

  • @dependent-wafer-177
    @dependent-wafer-177 8 лет назад

    5min in and I already started getting it. Awesome explanation.

    • @lovedennes2409
      @lovedennes2409 8 лет назад

      GlennBen dax cf j u yucjjcjx?cjcjcj cc j4

  • @jacquelineyoung6908
    @jacquelineyoung6908 7 лет назад

    This was an excellent way to explain the MVC structure.....I have more clarity....thanks

  • @sandeepvk
    @sandeepvk 8 лет назад +18

    thanks Jacurtis, very well put together video. I now understand MVC now

  • @majia
    @majia 8 лет назад +15

    oh my gosh, i finally understand MVC @__@ thank you

    • @1rui18
      @1rui18 7 лет назад

      tu tambem és.....

  • @ramyar6785
    @ramyar6785 7 лет назад

    one of the best best tutorial to learn MVC

  • @hehythrjkljwqoi
    @hehythrjkljwqoi 8 лет назад +1

    Amazing, now it makes sense, I will remember this thing throughout my life!
    Thank you.

  • @haalamn877
    @haalamn877 3 года назад

    Finally understood MVC, thanks dude a sub is what u deserve

  • @blackmediapodcast
    @blackmediapodcast 7 лет назад +2

    Very clear and concise. I love learning about the principal and/or concepts before focusing on the "how" - Great! explanation.

  • @erickmclark
    @erickmclark 7 лет назад +1

    Wow!!! I thought I would never get this concept. Thank you a lot!! So easy to understand!

  • @carlareis9220
    @carlareis9220 2 года назад +1

    Awesome explanation! Thank you!!!

  • @RmaNYouTube
    @RmaNYouTube 7 лет назад

    Thanks Very much but please make a video only explaining route processing process , i still can't get my head around it properly.

  • @petebryant
    @petebryant 4 года назад +2

    you can probably skip to 14:30 actually

  • @DraxTheDestroyer
    @DraxTheDestroyer 2 года назад

    100Devs brought me here, thanks for the lesson!

  • @neanda
    @neanda 4 года назад

    thank you, I understand MVC now (UI designer here)

  • @aiden7274
    @aiden7274 8 лет назад +1

    Best explanation of the MVC structure, love the presentation!

  • @supersu6138
    @supersu6138 4 года назад

    The best explanation of mvc

  • @parthsharma4041
    @parthsharma4041 7 лет назад

    2 mins in and its already so awesome lol, thanks for this well done

  • @reubenalfred4878
    @reubenalfred4878 3 года назад +2

    You've got to be careful when you watch this video as terms are not used rigorously but loosely. Structure, Process, workflow... The database is NOT the model. The view is Not the client and the server is NOT the controller!!!
    i would recommend watching other videos on this subject too and comparing them but don't use this as just one video to understand the concepts!!!

  • @saptarshideysikder755
    @saptarshideysikder755 7 лет назад

    Thanks for the video..Really understood the MVC. Was having difficulty understanding before watching the video.

  • @mandy2533
    @mandy2533 8 лет назад +20

    This should have been required to watch the first day of my internship :(

    • @zhrxxo6610
      @zhrxxo6610 4 года назад

      GOSH IK THIS WAS 3 YEARS AGO BUT IT WAS SO RELATABLE, dude just give us one vid which is not beginners friendly at all T.T

  • @kinsleyKJV
    @kinsleyKJV 7 лет назад

    this really helped me thank you for the tutorial, now i get it .... i have a history of not getting it ...now i get it thanx

  • @bensmith807
    @bensmith807 6 лет назад

    This is by far the most helpful explanation!!

  • @marcosantonioosoriovillalo313
    @marcosantonioosoriovillalo313 8 лет назад

    I finally can understand MVC. many thanks to you!

  • @I_Am_McZee
    @I_Am_McZee 9 месяцев назад

    Very clear and very helpful. Very solid explanation!!!

  • @lathrox8365
    @lathrox8365 7 лет назад

    Makes so much sense. Going to implement this arcitecture in my java program asap.

  • @mohammadghonchesefidi9238
    @mohammadghonchesefidi9238 6 лет назад

    Good job. I was learning Django and I had problem understanding the concepts. Thanks a lot.

  • @creidieki
    @creidieki 6 лет назад

    You say the View never talks to the Controller, but I thought the View was the part that the user was typing into and clicking things on. When the user clicks a UI button, isn’t that button part of the View? If not, what is it a part of?

  • @krillenummer1
    @krillenummer1 7 лет назад

    You are my savior! Great and clear information that gave me that ahaaa-experience that filled in all the missing gaps i had to understand MVC! Keep up the great work and will be watching your other videos as well!

  • @Sim1305
    @Sim1305 8 лет назад

    nicely presented. one question, can we say route processor is a navigation controller which find and delegate the work to required controller?

  • @supunsandeeptha2249
    @supunsandeeptha2249 6 лет назад

    So Basically Model is the Database ? Controller handles the business logics and view is the UI ?

  • @erjonhazizaj1707
    @erjonhazizaj1707 8 лет назад

    yours tutorials are amaizing, i love them, i am following you in every laravel tutorial

  • @charlesbovalis6591
    @charlesbovalis6591 5 лет назад

    I truly APRECIATED this video and I finally understand the essence of MVC

  • @TheRiotousMind
    @TheRiotousMind 7 лет назад +2

    I just started a Python/Django project and was feeling like I was in over my head. This definitely helped out a lot. Thanks!

  • @jnfrle
    @jnfrle 5 лет назад

    Thanks! I'm using Spring MVC and this gave me the background I wanted, including the history in the beginning.

  • @ghaleda1785
    @ghaleda1785 8 лет назад

    Finally Jacurtis... thank you so much for this video... you made it!

  • @sudharshantr8757
    @sudharshantr8757 2 года назад

    How is MVC different from 3-tier architecture: client layer - business logic layer - database layer ?

  • @chuksogor4267
    @chuksogor4267 7 лет назад

    Thank you so much, finally understand MVC patterns

  • @KedemHai
    @KedemHai 7 лет назад +19

    This is not MVC. it's kind of close to MVP, but not completely. actually what you've described would negate the whole purpose of MVC, MVP, MVVM etc. What in the heart of any of those architecture is separating the Model from the View. the Model is a GIVEN(!) and so is the View, what separates them can be a Controller, a Presenter or just a ViewModel, but none of them know nothing about the View, or else our View will never be reusable because it still has a 1:1:1 relation with the Controller and the Model.
    With MVC the Controller just updates the Model with the user's request (i.e. the operation the user wish to do on the data, such as 'give me a list', 'save this item' etc.) and then leave it for a View to query the Model and be able present the same data in many different ways, regardless the controller that updated the model.

  • @NethiestChannel
    @NethiestChannel 7 лет назад +3

    Technically, the view t alks to controller via interface.
    Directly or indirectly.

  • @LEGnewTube
    @LEGnewTube 7 лет назад +1

    Most clear presentation I have ever seen on MVC. Thank you for clearing up my confusion.

  • @thadeuszl5518
    @thadeuszl5518 8 лет назад +11

    Is it possible that you described a MVP? What would you say is the difference between MVC or MVP?

    • @jorgeherrera1074
      @jorgeherrera1074 8 лет назад +3

      I think so, right? Not sure this is a MVC... wouldn't a view AND the controller talk with the Model?

    • @OctaBech
      @OctaBech 8 лет назад +4

      Yes it's definitely not the MVC pattern described in my uni text books. The Controller isn't supposed to be an Adapter for communication from Model to View, but only (for user input) from View to Model.
      Oh well, as long as one uses the pattern to solve a problem and not just to use a pattern for the sake of using patterns, it should be fine.

    • @richmetellus5585
      @richmetellus5585 6 лет назад

      Yes he is explaining the MVP pattern design. This stack overflow link explain the difference stackoverflow.com/questions/2056/what-are-mvp-and-mvc-and-what-is-the-difference

    • @calvin_1983
      @calvin_1983 6 лет назад +2

      The MVP in 1992 was Michael Jordan.

    • @fakewalka
      @fakewalka 6 лет назад

      hitman98761 you just made my day :D

  • @Georgii1212
    @Georgii1212 4 года назад

    Can you please explain in which layer are the business logic and business objects?..in Model? or in Controller?

  • @nazrul-geeti
    @nazrul-geeti 6 лет назад

    Perhaps the best explanation of MVC with great examples which help visualize/understand/encourage to explore & learn!! Great voice too by the way!! Keep them coming!

  • @toastedbagel2100
    @toastedbagel2100 7 лет назад

    Thank you so much for these, I really enjoy your way of visually showing what's happening in your videos.

  • @TimEckel
    @TimEckel 7 лет назад +1

    Still confused. Not by this video, but when I actually look at MVC code it makes no sense. In Laravel for example, routes are in their own folder, and the views are in the resources/views folder, but where's model and controllers? I can find a Controllers folder in the app/Http folder, but it doesn't seem to do anything (there's no logic in it). I can't even find a "model" folder at all. So if it's MVC, why is everything hidden and mislabeled?
    And why does this make things easier? I typically see people repeating code to a MUCH higher degree with MVC. It seems like you need to do the same thing over and over again with MVC. Totally lost, and this video only confuses me more because while it seems simple, I can see nothing simple about any program that uses the model.

    • @eugen-lucianpasca5116
      @eugen-lucianpasca5116 7 лет назад

      Hello, Laravel has a strange strucutre. You could check this tutorial series where you can learn how more about it. laracasts.com/skills/laravel

  • @YoMandz
    @YoMandz 7 лет назад +1

    This was so good. Have been struggling for so long, thank you!

  • @selfmadetool
    @selfmadetool 5 лет назад

    Thank you for recording this tutorial.

  • @RandomAlexus
    @RandomAlexus 6 лет назад

    yeah this is a great description of MVC

  • @s.nikolic497
    @s.nikolic497 7 лет назад

    best video I have seen on MVC

  • @kossyoto1
    @kossyoto1 6 лет назад

    Thanks very much! Not it is a lot more clear to me what's going on with this MVC mystery. Thanks for clarifying!

  • @kaysoftdev5608
    @kaysoftdev5608 7 лет назад

    thank you i finally understand MVC funny enough i have been doing what seems to be MVC

  • @miggiegarcia6213
    @miggiegarcia6213 3 года назад

    MVC was really easy to understand and follow. I posted some comments for study notes and space repetition on my dev twitter account.

  • @marcusedwards8248
    @marcusedwards8248 7 лет назад

    One question...when describing the model you mention that the "controller never talks directly to the database" . Then when describing the controller you state that it "processes info and talks to the DB if needed". So would specific query statements reside within the controller or with the script files that define the data model? I would love to see a simple app directory structure explained in MVC context.

    • @JacurtisTutorials
      @JacurtisTutorials  7 лет назад

      Sorry, what I meant to say is that if the controller needs something from the database, it will ask the MODEL to get it. So the controller talks to the model, and the model is what is running queries on the database, generally restructuring it, and passing it back to the controller.
      Another concept I didn't cover in this video is that often the Model is not just a database abstraction as many people think, but instead the model might have logic in it which manipulates the database information. This further illustrates the point that the controller doesn't need to have any awareness of the database's structure. So as an example, lets say you set up something in your database called soft deleting. This enables you to "delete" a record without actually removing the database row. This is often done by adding a timestamp to a nullable deleted_at column or making a column value true. The point is the controller doesn't have to be concerned with how the database is set up. If it asks for all the records, the model can give it all of the records which have not been "soft-deleted" by default whenever any request is made to the model. The model knows and understands the DB structure, and the controller doesn't have to worry about it, it simply requests the information it needs from the model and the model translates it as needed.
      Another example is that sometimes your model might parse data from a column, before handing it off to the controller, it might combine columns as relevant for certain requests. For example, maybe the controller wants all the active users, and it makes an "activeUsers" request to the model. Well your database might not have an "active" column but your model knows that a user that made at least one post this month is considered active, well the number of posts a user has is most likely in an entirely different table. So it can query the DB appropriately and effectively give the active users to the controller as it requested, despite the fact that "active users" is not something that even the database knows it contains, it is performed as part of the model. The controller asks a simple question: "Can i get all the active users" and the model knows, "ok, i need to find out which posts were made this month and which users posted them, to see who was active this month.". The model does its job and then passes all active users to the controller. The controller doesn't know whether an "active" column exists or whether some type of join between two tables had to be made. It is a separation of concerns, and thats the fundamental concept that MVC provides.

  • @BuddhaAfterDark
    @BuddhaAfterDark 3 месяца назад

    great video! great explanation. I finally understand MVC!

  • @quentinmisslin8801
    @quentinmisslin8801 6 лет назад

    Awesome tutorial, thank u !! And thank sooo much for no background music ! 💗

  • @zakriaeric9333
    @zakriaeric9333 Месяц назад

    I have a question that mvc is used for managing the code or develop the application😢

  • @chaoticsoap
    @chaoticsoap 6 лет назад

    So if I'm understanding the model correctly this is wrong 17:57
    The controller doesn't talk to DB but to the model and doesn't recieve info from DB but again, from the model.

  • @trancevision83
    @trancevision83 8 лет назад +10

    That was amazing explanation. Thank you!

  • @RioTheHitman
    @RioTheHitman 8 лет назад

    Great vid man I've been using MVC so long but didnt realize its called this...I've always programmed in this way because it makes things flow so much better

  • @NikhilTarte
    @NikhilTarte 7 лет назад

    @DevMakerter, One Question, if Suppose I don't have a Database to deal with in my project, so What Will be MVC, or this architecture is going to Matter?
    If my project is having Complex algorithm to deal with the database, processing input data and then save. Is that Algo Model or Controller?

  • @iamthe1234567890
    @iamthe1234567890 6 лет назад

    thanks dude. this is much more helpful than stackoverflow answer.. will check out your laravel tutorials later as i want to learn it

  • @naveenbhandari6095
    @naveenbhandari6095 7 лет назад

    Finally. Understood. Thanks man.!!