I couldn't get it to work either, but I took the basic concept and made my own version of this hack.
In this version, you don't have to add the extra parameter '&autonext=true', which should make integration into coppermine much easier.
It worked on my system, which is slightly modified to display in Joomla, but I believe the code changes needed for this mod are independent of my other modifications.
In themes.inc.php, find
function theme_html_rating_box()
{
global $CONFIG, $CURRENT_PIC_DATA, $CURRENT_ALBUM_DATA, $THEME_DIR;
global $template_image_rating, $lang_rate_pic;
And replace with
function theme_html_rating_box()
{
global $CONFIG, $CURRENT_PIC_DATA, $CURRENT_ALBUM_DATA, $THEME_DIR;
global $template_image_rating, $lang_rate_pic, $pos, $album;
Same file, find
'{RATE0}' => "ratepic.php?pic=$pid&rate=0",
'{RATE1}' => "ratepic.php?pic=$pid&rate=1",
'{RATE2}' => "ratepic.php?pic=$pid&rate=2",
'{RATE3}' => "ratepic.php?pic=$pid&rate=3",
'{RATE4}' => "ratepic.php?pic=$pid&rate=4",
'{RATE5}' => "ratepic.php?pic=$pid&rate=5",
and replace with:
'{RATE0}' => "ratepic.php?pic=$pid&rate=0&pos=$pos&album=$album&cat=".$_GET['cat'],
'{RATE1}' => "ratepic.php?pic=$pid&rate=1&pos=$pos&album=$album&cat=".$_GET['cat'],
'{RATE2}' => "ratepic.php?pic=$pid&&rate=2&pos=$pos&album=$album&cat=".$_GET['cat'],
'{RATE3}' => "ratepic.php?pic=$pid&rate=3&pos=$pos&album=$album&cat=".$_GET['cat'],
'{RATE4}' => "ratepic.php?pic=$pid&rate=4&pos=$pos&album=$album&cat=".$_GET['cat'],
'{RATE5}' => "ratepic.php?pic=$pid&rate=5&pos=$pos&album=$album&cat=".$_GET['cat'],
In file ratepic.php, find
$location = "displayimage.php?pos=" . (- $pic);
And add directly after it:
if (isset($_GET['album'])) $location = "displayimage.php?album=".$_GET['album']."&pos=".($_GET['pos'] + 1)."&cat=".$_GET['cat'];