Breadcrumb like Site Breadcrumb like Site
 

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

Breadcrumb like Site

Started by SolidSnake2003, December 27, 2013, 06:58:41 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

SolidSnake2003

Is it possible to change the theme_breadcrumb in coppermine to match my site's system.  I have the photo gallery as a different section of the site.  So I would like it to be like this

home img Solid Snake: A Hero's Legacy
sep img Photo Gallery
cur img gallery index/categories/albums/pics etc

http://www.solidsnakelegacy.net/gallery

Αndré

The answer is probably "yes", unfortunately I don't understand
Quote from: SolidSnake2003 on December 27, 2013, 06:58:41 PM
home img Solid Snake: A Hero's Legacy
sep img Photo Gallery
cur img gallery index/categories/albums/pics etc
i.e. what exactly should be changed how.

SolidSnake2003

Im wanting it to look like vBulletin's old version 3 breadcrumb

Ive attached an image example of how it looks.

Plus Im wanting the breadcrumb trail to match the site as well.  Instead of this

Home sep Category/Categories sep Current Location

I want it to look like this:

Solid Snake: A Hero's Legacy sep Photo Gallery sep Category/Categories
Current Location


Αndré

So you actually want to replace the word "Home" with your website's name plus "Photo gallery" and move the current location one line below, correct?

SolidSnake2003

Exactly

Is it also possible for me to move it somewhere else in the html

Αndré

Copy this to your theme's theme.php file:
function theme_breadcrumb($breadcrumb_links, $BREADCRUMB_TEXTS, &$breadcrumb, &$BREADCRUMB_TEXT)
{
    $breadcrumb = '';
    $BREADCRUMB_TEXT = '';
    global $CONFIG;
    $breadcrumb_links[0] = '<a href="../">'.$CONFIG['gallery_name'].'</a> > <a href="index.php">Photo gallery</a>';
    for ($i = 0; $i < count($breadcrumb_links)-1; $i++) {
        $breadcrumb .= ' > ' . $breadcrumb_links[$i];
    }
    $breadcrumb .= '<br /> &nbsp; > ' . $breadcrumb_links[$i];
    foreach ($BREADCRUMB_TEXTS as $BREADCRUMB_TEXT_elt) {
        $BREADCRUMB_TEXT .= ' > ' . $BREADCRUMB_TEXT_elt;
    }
    // We remove the first ' > '
    $breadcrumb = substr_replace($breadcrumb,'', 0, 3);
    $BREADCRUMB_TEXT = substr_replace($BREADCRUMB_TEXT,'', 0, 3);
}

SolidSnake2003

Thanks, worked exactly as I wanted, marking as solved.

allvip