Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
CptFox16167yIt's a design pattern, a way of designing a program. MVC stands for
- Model : this is where actual functionality is implemented, it does the work
- View : this displays the Model's data to the user. It usually implements interfaces that the model will call to, so that you can change the view easily with little changes to the model.
- Controller gets user input, I personally have a very hard time distinguishing it from the View
If anyone knows this better than me, please correct me, I'm not 100% sure I got it right -
-
@linuxxx well I got taught MVC wrong three times (at the same school teachers were debating).
Then I followed the internet, my colleagues and frameworks. Which taught me the right way. -
The M in MVC are the models containing the data for the view aka classes mirroring your database
The V is the viewlayer where the data from the models is being displayed in a markup language
The C are the controllers responsible for passing the models to the viewlayers and also containing state about the views
Check out MVVM (should be MCVMV) where a View Model is added, which get's responsible for representing the whole state of the view (combination of models and UI state) which leaves the controller with the task to just present the models
Add some repositories and services with dependency injection and your good to go ;)
Sorry for the long comment, hope this helps -
@phexter you are right, but a database isnt just the one you think of righr away. An txt file is also an ini file is also a database according to the global definition.
-
@phexter This is the first time I hear this pattern, thank you very much everyone !! ^_^
Related Rants
-
cjaro15I just solved a problem that the CTO and senior devs couldn't get!!! I'm on top of the world!!
-
gosubinit18This genius made his very own super-flexible-and-versatile-never-seen-before-mvc-framework, with no documentat...
-
DangerousDev11Fuck the incompetent and "pretentious psuedo devs" !! I have been developing a web portal for a student club ...
!rant
But... WTF is MVC? Microsoft Visual C++?
I'm crawling with acronyms :/
undefined
don't punch me please
acronyms
mvc
not in face