coppermine-gallery.com/forum

Support => cpg1.4.x Support => Older/other versions => cpg1.4 miscellaneous => Topic started by: Infernal on January 13, 2008, 02:55:44 PM

Title: Removing keyword pulling from db from displayimage.php
Post by: Infernal on January 13, 2008, 02:55:44 PM
Well you gave me a good idea [GauGau thanks]
How can i eliminate the part of the displayimage.php that pulls information from the db
like the keywords
GauGau once just checked out a cached page from google and showed me my picture keywords in the image page
How can i take those parts out so it will not pull out so many things out of the database special all keywords related things
Title: Re: Removing keyword pulling from db from displayimage.php
Post by: foulu on January 15, 2008, 08:24:21 AM
Open "displayimage.php"

Search:

if ($CURRENT_PIC_DATA['keywords']) { $meta_keywords = "<meta name=\"keywords\" content=\"".$CURRENT_PIC_DATA['keywords']."\"/>"; }

and replace it with:

// if ($CURRENT_PIC_DATA['keywords']) { $meta_keywords = "<meta name=\"keywords\" content=\"".$CURRENT_PIC_DATA['keywords']."\"/>"; }

if you don't want to show keywords on picture information, then search:

if ($CURRENT_PIC_DATA['keywords'] != "") {
    $info[$lang_picinfo['Keywords']] = '<span class="alblink">' . preg_replace("/(\S+)/", "<a href=\"thumbnails.php?album=search&amp;search=\\1\">\\1</a>" , $CURRENT_PIC_DATA['keywords']) . '</span>';
}


and replace it with
/*
if ($CURRENT_PIC_DATA['keywords'] != "") {
    $info[$lang_picinfo['Keywords']] = '<span class="alblink">' . preg_replace("/(\S+)/", "<a href=\"thumbnails.php?album=search&amp;search=\\1\">\\1</a>" , $CURRENT_PIC_DATA['keywords']) . '</span>';
}
*/

Title: Re: Removing keyword pulling from db from displayimage.php
Post by: Infernal on January 15, 2008, 01:49:07 PM
thanks a lot
i guess the keywords still work it only does not show them right ?