Hello,
I'd like to put an image or text along the gallery name if a certain gallery is new or updated in the last month or so.
Has anyone done this before? I did a forum search, but the search terms I tried didn't really deliver anything on this subject.
Any help would be greatly appreciated!
Thanks!
Please, is there anyone that can help me with this? I'm puzzled on how to tackle this :(
Use bbcode (http://coppermine-gallery.net/demo/cpg14x/docs/index.htm#bbcode) in the album description.
Thank you for your reply, but this is a manual action that I have to do when I add new galleries?
I'd like to automate it. Check the album's last update date/time and if it is within for example 1 month of the current date/time,
then put *New* behind the album title or something like that.
Is this possible at all?
Possible if you code it.
Ok I finally managed this myself. Thanks for the tips with the bbcode and stuff.
I know this change is not ideal (change to index.php, so might cause problems when upgrading), but it works fine for me now.
I changed
$alb_list[$alb_idx]['album_desc'] = bb_decode($alb_thumb['description']);
to
if (time()-$alb_stat['last_upload'] < 2592000) //if the album is created or updated in the last month, put a "NEW icon" in the description
{
$alb_list[$alb_idx]['album_desc'] = bb_decode('[IMG]http://front242.digitality.be/gallery/themes/f242/images/new.gif[/IMG]'.$alb_thumb['description']);
}
else
{
$alb_list[$alb_idx]['album_desc'] = bb_decode('[IMG]http://front242.digitality.be/gallery/themes/f242/images/blank.gif[/IMG]'.$alb_thumb['description']);
}