Jump to content

How to use MVC without a Framework?


lopes_andre
 Share

Recommended Posts

Hi,

 

I'm a newbie in PHP Object Oriented.

 

I will build a website using PHP OO. I have tested many frameworks... Zend Framework I think it is very complicated to an OOP newbie, CodeIgniter seems more friendly... but I'am a newbie in PHP OOP... if I start coding with a Framework I will never learn the PHP OOP concepts, I will only learn the Framework...

 

There is some possibility to use the MVC without any Framework? If yes, there are some examples online?

 

 

Best Regards,

André.

 

 

Link to comment
Share on other sites

I don't agree that you'll learn "only the framework". Frameworks are constructed using the object-oriented programming rules, patterns etc., so you can see right there, how to model many concepts in OOP.

 

Anyway, MVC is just a design pattern, not a library or a piece of code. It is a formula that tells, how to organize YOUR code in order to get some specific properties. Frameworks simply follow this formula and your code can follow it, too.

Link to comment
Share on other sites

  • 1 year later...

Hey guys,

 

Few years ago, i created my first wap forum, and after that, somehow I just stopped programing. Just got tired of it. Now, i was doing some research on web design, and oop. I have tried codeigniter, and I would use it, but, i got into college after school, and I'm studying programing for computers. So, my final task in this college, will be create a website, so, i wanna start working on it. So, codeigniter will not work, because it's too easy, yes, to start learning oop, it's okay, but really, almost everything you need is in the library folder, and I want more challenges :D i googled for php mvc tutorials, found few, but there was more code than text that explains it. What do I want from you, you may ask. Well, I want you, to explain me, how to create my own mvc core. Little bit off topic: how the heck does codeigniter rewrite urls without .htaccess? Thanks for any help! Sorry for my bad english

Link to comment
Share on other sites

Well, I want you, to explain me, how to create my own mvc core.

 

MVC is just a design pattern. It's not rocket science, and it is definitely not the be all and all.

 

I posted a very simple example a few years ago, maybe it will help. http://www.phpfreaks.com/forums/application-design/fully-understanding-mvc-concept/msg729041/#msg729041

 

That entire thread might be worth you reading actually.

 

how the heck does codeigniter rewrite urls without .htaccess?

 

It doesn't. All requests go to a single entry point (the front controller) which then parses the url and executes the correct controller / action.

Link to comment
Share on other sites

This thread is more than a year old.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.