Re: Website too slow
Available news archives: comp.lang.tcl - comp.lang.python - comp.security.firewalls - sci.crypt - comp.lang.php - comp.lang.javascript
Google
 
Web news.hping.org


comp.lang.php archive

Re: Website too slow

From: Ken Robinson <kenrbnsn@rbnsn.com>
Date: Mon Jul 18 2005 - 13:41:11 CEST

bettina@coaster.ch wrote:
> I'm re-programming my Website (www.coaster.ch) in PHP and I find it too
> slow (although I have ADSL).

Speed of execution of PHP has nothing to do with the speed of your
connection. It has to do with the efficiency of your code and the speed
of the host.

> That's more or less how it functions:
> Here my tables:
> 'COASTERS' (code of coaster, code of country, etc...)
> 'COUNTRIES' (code of country, names of countries in different
> languages, code of continent)
> 'CONTINENTS' (code of continent, names of continents in different
> languages)
>
> In my index.php (start site) I use a "while":
> I look for the first continent.
> I look for the first country
> I count all the coasters from 1st country
> echo country - number of coasters
> I look for the second country
> I count all the coasters from 2nd country
> ...
> ...

May we see you code. Without it, we will not be able to tell you how to
speed it up. It may be as simple as using a built in function instead
of a loop, or it could be a redesign of your logic.

Ken
Received on Mon Oct 17 21:09:57 2005