Add all pictures/files from a particular album to your favorites - Page 2 Add all pictures/files from a particular album to your favorites - Page 2
 

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Main Menu

Add all pictures/files from a particular album to your favorites

Started by Αndré, April 27, 2009, 08:45:39 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

peterlustig

thanks a lot for your support! however, replacing the function didn't help :(  (I did so by changing a version of `codebase.php' on my harddisk and then transferring on the plugins folder via ftp, overwriting the existing file)

No seemingly change in what's going on, I still get a blank page when clicking on an album....

Αndré

Can you give me ftp access to your plugin directory? If yes, I'll give you my email address.

peterlustig


Αndré

Problem solved. Your PHP version is too old for my plugin. The count parameter was added in PHP 5.1.0.

Everyone who is running PHP < 5.1.0 please replace the entire function album_addfav_html with the following code:
function album_addfav_html($html) {
    $html = preg_replace('/<td width="100%" class="statlink"><h2>(.*)<\/h2><\/td>/Usi', '<td width=\"100%\" class=\"statlink\"><h2>\\1 <a href="index.php?file=album_addfav/album_addfav&album='.$_GET['album'].'" title="Add album to favorites"><img src="plugins/album_addfav/favorites.png" border="0" style="display:inline" /></a></h2></td>', $html);
    $html = preg_replace('/<td width="100%" class="statlink">(.*)<\/td>/Usi', '<td width=\"100%\" class=\"statlink\">\\1 <a href="index.php?file=album_addfav/album_addfav&album='.$_GET['album'].'" title="Add album to favorites"><img src="plugins/album_addfav/favorites.png" border="0" style="display:inline" /></a></td>', $html);

    return $html;
}

Joachim Müller