Why use PHP OOP over basic functions and when?

后端 未结 10 1912
深忆病人
深忆病人 2020-12-04 13:14

There are some posts about this matter, but I didn\'t clearly get when to use object-oriented coding and when to use programmatic functions in an include. Somebody also ment

10条回答
  •  春和景丽
    2020-12-04 13:43

    The OOPs concept is used in PHP, so as to secure the code. As all the queries are written in function file instead of code file so no one can easily hack our code. So it is better to use classes in PHP instead of directly writing the queries.

提交回复
热议问题