Do you know a good book / website about structuring your codes (PHP / Web programming)

I mainly use PHP, and I programmed it for a while. My main problem with PHP is that I think that as your program grows, it becomes more difficult to maintain your code (maybe it applies to other things). I want to reduce this complexity when saving / modifying my codes. I want to make things modular and have rules when to start a new class or just add to an existing class (for example). I know there are frameworks (CakePHP, Symfony, Rails), but what if I just want to use my PHP and use a hybrid of my own style and an existing style for good code management?

+5
source share
6 answers

This not only applies to php, it applies to coding in general. The framework will help you organize the mess, but if you are new to programming, the platform will organize your messy code.

Some basic ideas to keep in mind, in addition to studying computer science (which I recommend if you are serious about coding), should make your code modular.

For example, and this is a simple example showing a point. If you have a website that generates an html table containing financial data.

(Here are some scenarios on how to do this ...)

  • , financialdata.php, 1 N, (, ), html.

  • , financialData2.php, , yuor ( ), . financialData2.php.

  • , financialData3.php, financialData2.php yoru. html , . , , financialData3.php , , .

: , . , , , .

-, , , . , . . ( ). - , -. , , getData .

/ , , , , , - , ​​ BS CSE, .

+4

( Java/C/.Net , ), Code Complete , . , , . , PHP, , , .

+1
0

All Articles