I recently noticed that when listing images in a SUB category by last uploaded or last commented, you were unable to click the thumbnail to view the intermediate image, as you would get the following error:
Fatal error: Call to undefined function: db_query() in /home/hiresco1/public_html/gallery/displayimage.php on line 259
I don't know anything about php, so I messed around to try and get it working. After removing line 257:
$res = db_query("SELECT COUNT(*) FROM {$CONFIG['TABLE_COMMENTS']} WHERE pid='{$CURRENT_PIC_DATA['pid']}' AND author_id = ".USER_ID);
it worked perfectly. Obviously I am a bit concerned about removing code, as I do not know what else it will affect. Can anyone help me?
That is 1.3 code. Why is it in your 1.4 gallery? Replace displayimage.php with a clean copy from the download package.
Thanks for the reply. I have no idea why it is in there. I will replace it. Thanks
;D Thanks. Works perfectly now!
If you updated your gallery from 1.3 to 1.4 then there may be other old files, use versioncheck.php.