8 Ways to Fine Tune your PHP Programming

PHP
Today I am going tell you some methods which will help those learning PHP & also those who are planning to start learning PHP. For those who are planning to learn PHP, I just want to say that every programming language has the same logic only the grammar (coding style or structure) changes.

1. Always follow the standard method of coding e.g. writing a single if statement without the curly braces {} works but always use them since this will result in easy updating in future.

2. Use comments to result in better understanding of the code. And also saves a lot for another programmer.

3. In case of any doubt, always refer to the online PHP Manual since it has a unique feature of adding the user comments which may provide better understanding of the issue. And also saves a lot of time since it minimizes the risk of any possible bug in the final program.

4. Use an IDE for PHP development just to enhance your programming skills and will also save a lot of time. Like NuSphere PhpED IDE(http://www.nusphere.com/). Even you can try Wamp Server or XAMPP for running your PHP scripts at your end.

5. Try to reduce the HTTP Request of files. It will in turn reduce the server load & increase the processing speed.

6. Always write a detailed list of things you expect your program to do. In technical terms, a Software Requirement Specification (SRS). So that you clearly know what you are going to do? Read this post for Writing SRS.

7. Use PHP Cheat Sheet or Reference Sheet while coding just to minimize the risk of errors. PHP Cheat Sheet is a collection of all the syntaxes, structures, etc.

8. Always give credit if you borrow some idea or code from someone else. Since the most important thing is that we should not be only a programmer but a good programmer & for that we must show respect towards the community of programmers. This result in worldwide acceptance & support for your work.

Let us hope these points will help you in honing your skills in PHP.

Note: Few points are also applicable to other programming languages

Update: Beginning PHP5, Apache, and MySQL Web Development can be used as a desk reference for a ready reference.

5 comments / Add your comment below

  1. HI,

    This Article is very useful for those who planning for learn PHP. The easy tips will definitely attracts the php beginners. Thanks for your valuable information sharing.

    Thanks

  2. I agree with your point on curly brackets, commenting the code and using IDE and would like to also recommend learning to use a development kit as well as development enviroment would be a greate help as well.

    As for writting SRS I almost forgotten how to do it and just downloaded the sample and will do it again. It is a very helpful thing to use and have(I was looking for this).

    Thank you.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.