forum.coppermine-gallery.net
Support => Older/other versions => cpg1.2 PHPnuke/Postnuke Support => Topic started by: tkx on November 29, 2003, 10:00:38 am
-
if you are in a specific user album, the album name doesn't show up in the menu... you have to go all the way back to the user directory... Where can I fix this so that the album name shows in the "Home > User galleries > myuser > (missing part) ????
-
Is this in displayimage or thumbnails.php or? I am making a fix to displayimage as we speak and will post the code as a sticky.
-
modules.php?name=coppermine&file=displayimage&album=random&cat=&pos=-545
Is this in displayimage or thumbnails.php or? I am making a fix to displayimage as we speak and will post the code as a sticky.
-
Nope, didn't work...
also what's with "if ($this_id < 2) $this_name = 'Mr. X';" ??? was that for testing// :)..
Ok it's sounds like the problem I am just fixing try this and tell me if it works for you
replace:
if (is_numeric($album)) {
$cat = - $album;
$actual_cat = $CURRENT_ALBUM_DATA['category'];
breadcrumb($actual_cat, $breadcrumb, $breadcrumb_text);
$cat = - $album;
} else {
$actual_cat = $CURRENT_ALBUM_DATA['category'];
$RES = db_query("SELECT catname FROM {$CONFIG['TABLE_CATEGORIES']} WHERE cid='{$CURRENT_ALBUM_DATA['category']}' LIMIT 1");
if (!mysql_num_rows($RES)) cpg_die(CRITICAL_ERROR, sprintf($lang_errors['pic_in_invalid_album'], $CURRENT_PIC_DATA['aid']), __FILE__, __LINE__);
$actual_catname = mysql_fetch_array($RES);
$actual_catname = $actual_catname[0];
$breadcrumb_text = "$actual_catname > $lang_meta_album_names[$album]";
breadcrumb(0, $breadcrumb, $breadcrumb_text);
}
with:if (is_numeric($album)) {
$cat = - $album;
$actual_cat = $CURRENT_ALBUM_DATA['category'];
breadcrumb($actual_cat, $breadcrumb, $breadcrumb_text);
$cat = - $album;
} else {
$actual_cat = $CURRENT_ALBUM_DATA['category'];
if ($actual_cat >= FIRST_USER_CAT) {
$this_name = get_username($actual_cat - FIRST_USER_CAT);
$this_id = get_userid($this_name);
if ($this_id < 2) $this_name = 'Mr. X';
$breadcrumb_text = "<a href=\"$CPG_URL&cat=1\">User galleries</a> > <a href=\"$CPG_URL&cat=$actual_cat\">$this_name</a> > $lang_meta_album_names[$album]";
breadcrumb(0, $breadcrumb, $breadcrumb_text);
}else{
$RES = db_query("SELECT catname FROM {$CONFIG['TABLE_CATEGORIES']} WHERE cid='{$CURRENT_ALBUM_DATA['category']}' LIMIT 1");
if (!mysql_num_rows($RES)) cpg_die(CRITICAL_ERROR, sprintf($lang_errors['pic_in_invalid_album'], $CURRENT_PIC_DATA['aid']), __FILE__, __LINE__);
$actual_catname = mysql_fetch_array($RES);
$actual_catname = $actual_catname[0];
$breadcrumb_text = "$actual_catname > $lang_meta_album_names[$album]";
breadcrumb(0, $breadcrumb, $breadcrumb_text);
}
}
-
Oh ya... also, when it is doing:
if (is_numeric($album)) {
...
It is returning TRUE, so all it calls is:
$cat = - $album;
$actual_cat = $CURRENT_ALBUM_DATA['category'];
breadcrumb($actual_cat, $breadcrumb, $breadcrumb_text);
$cat = - $album;
I just did some echo "test"; in the code to see where it went..
-
code worked for me URL?
Mr.X is if you allow anon to have user albums. weird, but could happen.
-
Sent via PM... site not live, in beta phase :).
code worked for me URL?
Mr.X is if you allow anon to have user albums. weird, but could happen.
-
I see what your talking about and will fix in morning, good night....
-
I see what your talking about and will fix in morning, good night....
Thanks :). I went to bed right before you wrote this message :).
-
sweetdreams and we are after the breadcrumbs.
Please don't eat them to get the way to real life again.
Wait untill we placed on the right spots.
-
still waiting for some breadcrumbs... :P
-
*bump
-
Patience, this is not an easy solution and they will be fixed in v1.2.0 which will be out within the next day or so.