Welcome to TheCredence.com - You may like to subscribe to our RSS feed to stay updated.
I know- it is a necessary evil. One that not too many developers are skilled at- bug hunting. Bug squishing. Getting rid of those nasty, unprepared surprises that completely took you by storm.And too many web developers/php coders are inexperienced at tracking down and squishing bugs. Here, I’ll give you some simple tips and tricks in order to cut down on the amount of time it takes to kill bugs in three simple steps.
1-Look at the debug output
Which can sometimes be cryptic, and other times not actually seeing the correct error. For example, if you are missing an end bracket, it won’t give you the proper line at which the end bracket is missing. Only tell you that there was an unexpected end.
2-Save incrementally, and in different files.
This way you always have a working copy of your program. There are many utilities that do this for you- CodeSafe, SVN, RCS- the key is to use them and use them well. This way you can track down what caused a bug by viewing older code and comparing when it did work to when it did not work.
3-Use your gut
Surprisingly enough, this is often the best way to go. Instead of poring through lines of code and searching the debug output for clues- think about what you had just added, and why it might be causing an error. Your gut may be able to save your skin in this case.
Well, that’s all. Good luck and Happy Coding.
Links you may find interesting -
