Author Topic: Pages load very slowly  (Read 10764 times)

0 Members and 1 Guest are viewing this topic.

Offline Chris

  • 4images Moderator
  • 4images Guru
  • *****
  • Posts: 4.487
  • Did u ever stop to think and then forget to start?
    • View Profile
Pages load very slowly
« on: June 17, 2003, 04:41:48 PM »
This was really just copied from a post made by Jan and edited slightly for clarity.  :wink:
--------------------------------------------------------------------------------------

If you have a lot of images in your database, the random category image and random image are very expensive database queries because of "RAND()" in the ORDER BY clause.

Open includes/constants.php and try changing
Code: [Select]
define('SHOW_RANDOM_CAT_IMAGE', 1);
to
Code: [Select]
define('SHOW_RANDOM_CAT_IMAGE', 0);
This disables the category related random image.


If this does not help, change
Code: [Select]
define('SHOW_RANDOM_IMAGE', 1);
to
Code: [Select]
define('SHOW_RANDOM_IMAGE', 0);
This will disable the random image completely.

 

Post your comments here