Hi.
Working with PHP5, I'm suffering an odd issue with the load of my website, which is an application allowing users to register and to post question in a kind of forum/bboard.
It's made with some PHP classes I created (they write/read to/from mySQL tables), and uses Smarty.
But the first time one user access any webpage, it takes 5-10 seconds to load. Then the rest of pages visited by the same user go really fast, so I'm wondering what's wrong with my PHP app.
Do you have similar experiences? I'm considering:
- Smarty takes some seconds to compile
- App takes some second to handle session variables (I use a lot of them)
Any suggestion is welcome. Thank you very much,
--mark
My PHP site takes 10 secs to load the first page
Moderator: General Moderators
Re: My PHP site takes 10 secs to load the first page
Hard to say - look into microtime() & how it can be used to time your page. Time the different sections of your page to see what's taking the time.
Real programmers don't comment their code. If it was hard to write, it should be hard to understand.