This module will display random images from PhotoPlog in GARS. You must have both GARS Pro and PhotoPlog Pro installed for this modules to work.
- Please note that this module is beta and not supported.
- FTP the various PHP files into their corresponding directories on the server:
- Go to the ACP -> GARS -> Modules -> Register New Module and set the following options:
- Title: PhotoPlog Random Thumbs
- Module File: photoplog_random_thumbs.php
- Comma seperated list of templates to cache: GARS_mod_container
- Go to the ACP -> GARS -> Modules -> click a module set where you'd like the new module.
- Use the Add Modules box to add the new module to the Showthread page:
- Left drop down menu: PhotoPlog Random Thumbs
- Right drop down menu: the location you'd prefer
- Click the PhotoPlog Random Thumbs link:
- Cache Method: select either Don't Cache or On Edit/New Thread
- What is the maximum number of images to show: enter a positive number
- Set the remaining options as you'd prefer
- Visit a GARS-based showthread page on your site that uses the module set you selected in step three.
- Want random images from only the author of the first post to appear?
- In the /geek/gars/mods/display/photoplog_random_thumbs.php file find the following:
- Replace that line with the following:
WHERE moderate = 0 AND userid = " . intval($post['userid']) . "
- Go back to step five and select Don't Cache for the Cache Method
- Cost of installing this module?
- One query added to process the first post in a GARS-based showthread page using this module
- Trade-off with some overhead/processing if you choose to cache rather than not cache the module
- ORDER BY RAND() queries are notoriously bad in that they scan way too many rows in the table
- You can limit the number of rows that are scanned by selecting category IDs in step five
- If your equipment is weak or your gallery is large, test the module for performance