Sanjib Sinha Posted December 31, 2008 Share Posted December 31, 2008 What are the main differences between procedural and object oriented php? Can I relate these two? Quote Link to comment https://forums.phpfreaks.com/topic/138993-php-question/ Share on other sites More sharing options...
premiso Posted December 31, 2008 Share Posted December 31, 2008 They usually intertwine with each other. Object Oriented (which PHP is working to be more centered towards). Uses classes to house objects and functions to manipulate those objects. www.php.net/oop should go more in depth on PHP OOP. From what I know about procedural, is that is just writing the code for to just run, this is how most scripts are done and works great in PHP. If you are using PHP 4, I would stick to procedural over OOP, if 5+ I would go more towards the OOP. I could be wrong on my thinking of procedural, its been a while since I was in a class with the definitions but to answer your question, yes you can relate the two, PHP works just fine intermingling. Quote Link to comment https://forums.phpfreaks.com/topic/138993-php-question/#findComment-726950 Share on other sites More sharing options...
Sanjib Sinha Posted December 31, 2008 Author Share Posted December 31, 2008 They usually intertwine with each other. Object Oriented (which PHP is working to be more centered towards). Uses classes to house objects and functions to manipulate those objects. www.php.net/oop should go more in depth on PHP OOP. From what I know about procedural, is that is just writing the code for to just run, this is how most scripts are done and works great in PHP. If you are using PHP 4, I would stick to procedural over OOP, if 5+ I would go more towards the OOP. I could be wrong on my thinking of procedural, its been a while since I was in a class with the definitions but to answer your question, yes you can relate the two, PHP works just fine intermingling. So the future is OOP? Quote Link to comment https://forums.phpfreaks.com/topic/138993-php-question/#findComment-727150 Share on other sites More sharing options...
premiso Posted December 31, 2008 Share Posted December 31, 2008 They usually intertwine with each other. Object Oriented (which PHP is working to be more centered towards). Uses classes to house objects and functions to manipulate those objects. www.php.net/oop should go more in depth on PHP OOP. From what I know about procedural, is that is just writing the code for to just run, this is how most scripts are done and works great in PHP. If you are using PHP 4, I would stick to procedural over OOP, if 5+ I would go more towards the OOP. I could be wrong on my thinking of procedural, its been a while since I was in a class with the definitions but to answer your question, yes you can relate the two, PHP works just fine intermingling. So the future is OOP? I wouldn't say that exactly. I am sure PHP will let you work with it like it always has. OOP just makes certain tasks etc more efficient. It all depends on the script you are working on whether OOP would be the way to go or not. Quote Link to comment https://forums.phpfreaks.com/topic/138993-php-question/#findComment-727167 Share on other sites More sharing options...
Sanjib Sinha Posted January 1, 2009 Author Share Posted January 1, 2009 They usually intertwine with each other. Object Oriented (which PHP is working to be more centered towards). Uses classes to house objects and functions to manipulate those objects. www.php.net/oop should go more in depth on PHP OOP. From what I know about procedural, is that is just writing the code for to just run, this is how most scripts are done and works great in PHP. If you are using PHP 4, I would stick to procedural over OOP, if 5+ I would go more towards the OOP. I could be wrong on my thinking of procedural, its been a while since I was in a class with the definitions but to answer your question, yes you can relate the two, PHP works just fine intermingling. So the future is OOP? I wouldn't say that exactly. I am sure PHP will let you work with it like it always has. OOP just makes certain tasks etc more efficient. It all depends on the script you are working on whether OOP would be the way to go or not. Thanks you. I got my answer. I have to learn the procedural basic soundly. Quote Link to comment https://forums.phpfreaks.com/topic/138993-php-question/#findComment-727453 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.