PHP Beginner logo 40 article

Source: Internet
Author: User
Tags constant definition version control system
PHP Rookie logo 40 article

?

Recently read an article, wrote very incisive, share with you

If you still have the following phenomena, then you are still a novice PHP:
1. Do not use tools such as Phpdoc to properly annotate your code;
2. Turn a blind eye to an excellent integrated development environment such as Zend Studio or eclipse PDT;
3. Never used any form of version control system, such as Subclipse;
4. Do not adopt some coding and naming standards, as well as general conventions, can not be implemented in the project development cycle;
5. Do not use unified development method;
6. Do not convert (or) also do not validate some input or SQL query string (refer to PHP related functions);
7. Do not thoroughly plan your program before coding;
8. Do not use test-driven development;
9. Do not encode and test in error-enabled state;
10. Ignoring the benefits of the debugger;
11. Do not refactor your code;
12. Do not use a similar MVC pattern to separate the different levels of the program;
13. Do not know these concepts: KISS, DRY, MVC, OOP, REST;
14. Instead of return, output (echo/print) content directly in your function or class;
15. Ignoring the merits of unit testing or general testing;
16. Always return hard-coded HTML, but do not return pure data, strings, or objects;
17. Always hard-code "message" and "Configuration parameters";
18. Do not optimize SQL query statements;
19. Do not use __autoload;
20. Do not allow intelligent error handling;
21. Use $_get instead of $_post to do destructive transfer operations;
22. Do not know how to use the regular expression;
23. Never heard of SQL injection or cross-site scripting;
24. The simple configuration is not allowed, and the constructor of the class is not allowed to accept the parameter passing and then execute the Set/get method, or the constant definition at run time;
25. Do not understand the advantages and disadvantages of object-oriented programming (OOP);
26. Misuse of OOP without regard to the size of the case;
27. It must be equal to/need to make your code conform to OOP for the purpose of realizing reusable software;
28. Do not use the smart default value;
29. No single configuration file;
30. Do not want to expose the source of the document, but replaced by the. Inc suffix. php;
31. Do not use the database abstraction layer;
32. Can not maintain dry style, that is, do not repeat themselves, if you are always copying and pasting some things, indicating that you are poorly designed;
33. No implementation allows a function/class/method to do only one thing, nor can it be combined to use them;
34. The features of OOP, such as abstract classes, interfaces, polymorphism, inheritance, access control modifiers, are not available;
35. Do not use the existing design model to optimize your program system design;
36. Do not allow your users to define the base directory in case you have many files or directories;
37. Pollute namespaces, such as naming your library functions with common strings;
38. Table prefixes are not used when using database tables;
39. Do not use a unified template engine;
40. Do not focus on the existing PHP development framework, lazy to explore, in fact, the development of advanced ideas and beautiful code is contained therein

  • Related Article

    Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.