coppermine-gallery.com/forum

Support => cpg1.4.x Support => Older/other versions => cpg1.4 miscellaneous => Topic started by: dills84 on March 06, 2009, 05:03:50 PM

Title: Excluding entire category from meta albums?
Post by: dills84 on March 06, 2009, 05:03:50 PM
Hi there, I was just curious if anyone knew of a quick way to remove an entire Categorys albums from being displayed in the meta albums (lastup,lastcom,ect...). I tried using the "unwanted_metas" plugin, but i'd rather just have the gallery exclude it automaticly so i dont have to keep adding albums manually.

I tried changing this code in index.php
$result = cpg_db_query("SELECT description FROM {$CONFIG['TABLE_CATEGORIES']} WHERE cid = '$cat'");

To

$result = cpg_db_query("SELECT description FROM {$CONFIG['TABLE_CATEGORIES']} WHERE cid = '$cat' AND !cid = '41'");
category ID 41 is the cid i'm trying to ignore from the query. But only being a php novice this didnt work. And i got a database error whenever i clicked on a thumbnail view page.

Any suggestions? Thanks!