PDA

View Full Version : Template & Database Problem - Please Read! Desperate!


Alien
07-17-2003, 09:04 AM
Hey campers. :(

I really need a professional's help on this one.

While working on my new website tonight using vb 2.3.0 (which contains 2 skins at the moment, 1 default and one brand new one launching soon) all of a sudden I am getting MAJOR rendering delays... The queries count is perfectly fine, it's just the long delays.. I haven't installed any new hacks in the past 24 hours, and there should be no differences in load time...

Here's an example:
Generated in 6.13347697 seconds (99.54% PHP - 0.46% MySQL) with 19 queries. (forumhome used as example).

Sometimes it's as low as 5ish, sometimes it goes to 14 or even 30!

Something must have botched somehow in the database, this has never happened to me before. I have been editing the templates feverishly on a non-live account on my dedicated server (using php 4.3.2, and mysql 3.23.57 btw) for a week and all of a sudden BOOM!

The real kicker, is that if I go into UserCP, select the 'default' template, the renderings are way under 1 second! How do I fix and repair this? All code inside of the templates is flawless.

I tossed debug on, and I get this one large delay (but only when I have this SPECIFIC template selected!):

Query: SELECT * FROM usergroup WHERE usergroupid=6
Time before: 16.053761959076
Time after: 16.054703950882

table type possible_keys key key_len ref rows Extra
usergroup const PRIMARY PRIMARY 2 const 1


We're opening in the next few days and this was certainly the last thing I was expecting...

Thank you for ANY help you can provide!

Regards,
-Jason

Xenon
07-17-2003, 09:14 AM
Generated in 6.13347697 seconds (99.54% PHP - 0.46% MySQL)

that shows that it's not your db, but the php part which takes so much time.

maybe you have a loop in your phpinclude template?

Alien
07-17-2003, 09:34 AM
I copied the simple phpinclude from the speedy and working default template and it seems to be fixed! Now, to try to isolate exactly what piece of code there is slowing things down...

I only have two things in there, the template version of the front page avatar hack, and a call to the thumbincluder relating to Photopost. I'll report back. :)

You are my hero, Xenon!

* Alien is NOT worthy!

-Jason

Alien
07-18-2003, 08:31 PM
Just coming back for an update.. It was having some sort of issue with the thumbnailincluder that works with Photopost. I'm going to figure out what that's all about. :)

Thanks again for your VERY prompt help!
-Jason

Xenon
07-18-2003, 09:46 PM
You're welcome :)