Hello,

I wonder when do I have to use OOP (Object Oriented Programming) ?

I know a little bit about it, but do not know when to use it. I basically in the middle of developing a website backend. Suggestion and advise appreciated.

It's a choice. It will make it easier to create reusable blocks of code. Another advantage is that, when used properly, it will be easier to read and manage your code.

My opinion: if you develop a complex site start using it soon since it will help you keep your code organized and under control. But it might take some time to learn it and it is probably not a good idea to learn on a real project. Well, I am not sure if I was helpful at all with this answer.

PHP is heading the OOP direction more and more with every version. Getting familiar with OOP in PHP as soon as possible is probably a very good idea.

if the language supports it...All the time!!!

ok thanks guys. Another question: when we are programming using OOP, do we have to implement MVC (Model View Controller) concept ?

MVC is just one way of doing things. Learning it will help you understand most frameworks though, it's very common.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.