Develop Rock-Solid Code In PHP: Lay The Foundation, Part 1
By Amol Hatwar
2004-01-21
Reader Rating:

Build for speed
The last factor worth tackling is speed. Nobody wants to wait forever as your script tediously selects 300 or so entries from a database and displays the results on a page. Putting 20 results on 15 different pages that travel and load quickly on the user's browser is always a better idea. The user perceives the faster response-time as speed. Another easy mistake is to create pages dynamically each time a user visits a page. This does ensure that your site stays fresh, but PHP isn't too forgiving when the number of users increases. You should cache frequently served pages. Caching makes your application faster and reduces the load on the server.
Ensure that your code runs fast. Nobody likes waiting.
First published by IBM developerWorks
If you found this article interesting, you may want to read these as well:
» Protecting your PHP and HTML Source Code
» Publishing Newsletters Using PHP & MySQL - 4
» Publishing Newsletters Using PHP & MySQL - 3
» Publishing Newsletter Using PHP & MySQL - 2
» Publishing Newsletters Using PHP & MySQL
» Unix Webserver Crontab Basics
|