top 10 php expert tips

9
TOP 10 PHP EXPERT TIPS

Upload: arista-infotech

Post on 21-Feb-2017

51 views

Category:

Internet


0 download

TRANSCRIPT

Page 1: Top 10 PHP Expert Tips

TOP 10 PHP EXPERT TIPS

Page 2: Top 10 PHP Expert Tips

INTRODUCTION HOW TO BE AN EXPERT IN PHPCONCLUSIONS

Page 3: Top 10 PHP Expert Tips

INTRODUCTION PHP is a server-side scripting language designed primarily for web development but also used as a

general-purpose programming language.

Page 4: Top 10 PHP Expert Tips

GO OOPEntering the realm of object oriented programming sets you at an advantage and ensures you are ahead of the pack.

TRASH ANYTHING THAT ENDS WITH _ONCE()Just don’t be in a hurry to use them because they kill your server resources. Include_once () and require_once () tends to be extremely hard on server resources.

Page 5: Top 10 PHP Expert Tips

KEEP EVER REPORTING ONWhat every PHP programmer should be starting on a new project is to turn error reporting to E_ALL. Nothing feels better than running a project in full production mode without getting even one error.

PROTECT YOUR DATABASE The best and safest way is to use mysql_real_escape_string() for all database before it is added to the database. This function makes all strings safe in terms of quotes and other functions.

Page 6: Top 10 PHP Expert Tips

USE PHP’S INBUILT FUNCTIONSPHP has many built-in functions that can do what you need them to, so check out the manual to make sure you are doing it in the best way possible.USE POST NOT GETGET is simple to emulate, but POST is safer.

Page 7: Top 10 PHP Expert Tips

DRAW BEFORE YOU CODEWireframe your projects, even if you are just scribbling a few notes on a piece of paper.UNDERSTAND YOUR PROJECTYou cannot code a project that you do not fully understand. If you do not understand exactly what it needs to do, and how it needs to it, you cannot build it.

Page 8: Top 10 PHP Expert Tips

POLISH YOUR BASICS Revise your basics and execute them more efficiently.

CODE, CODE AND CODEYou cannot become a good developer by reading. The one and only tried and trusted method, is to actually write code.

Page 9: Top 10 PHP Expert Tips

CONCLUSIONIf you are a PHP developer, follow these 10 important PHP tips to develop a good PHP program.

Presented By: ARISTA INFOTECH