PHP+Markup+Pitfalls

PHP Markup Pitfalls

If you get errors or things do not work, check the following:

display_errors / error_reporting typos missing semicolons missing closing brace, bracket, or parenthesis using = instead of == headers already sent (using headers to redirect and having white space before header) not correctly encoding values of input/output not validating form values missing SQL escape character handling mistakes in crafting the SQL statement

Also, not refactoring code can result in lost time having to copy code from one place to another

.