coppermine-gallery.com/forum

Support => cpg1.4.x Support => Older/other versions => cpg1.4 themes/skins/templates => Topic started by: Gephri on January 25, 2006, 08:36:40 AM

Title: Possible to change the " > " in breadcrumb path
Post by: Gephri on January 25, 2006, 08:36:40 AM
Is it possible to change the " > " arrow that is the default pointer in the breadcrumb path to a more exciting image file on my site?

If so, can you please instruct... simple Img insertion has not worked.

Thanks in advance
Title: Re: Possible to change the " > " in breadcrumb path
Post by: Tranz on January 25, 2006, 08:46:42 AM
I don't see why not. Could you post the code you use?
Title: Re: Possible to change the " > " in breadcrumb path
Post by: Gephri on January 25, 2006, 08:47:59 PM
Typical image location in my root image file.  Code is:

<IMG src="/images/icons/arrw_y.gif" width="6" height="7" border="0" alt="arrw_y.gif" title="">

The problem in Coppermine is that the first instance of the new image doesn't show and instead shows the image code - except for the <I characters.

Thanks for the help in advance
Title: Re: Possible to change the " > " in breadcrumb path
Post by: Tranz on January 25, 2006, 09:04:26 PM
Could you post that line in the context of where you put it? Like a few lines before and after? We also need a link to the page where you see this.

Please try to provide as much detail as possible when requesting help.
Title: Re: Possible to change the " > " in breadcrumb path
Post by: Gephri on January 26, 2006, 08:37:54 AM
Sorry for being so cryptic - tried to not bore you with unneccesary info.

CPG Coding found in: functions.inc.php

// we check if the theme_breadcrumb exists...
        if (function_exists('theme_breadcrumb'))
        {
            theme_breadcrumb($breadcrumb_links, $BREADCRUMB_TEXTS, $breadcrumb, $BREADCRUMB_TEXT);
            return;
        }
        // otherwise we have a default breadcrumb builder:
        $breadcrumb = '';
        $BREADCRUMB_TEXT = '';
        foreach ($breadcrumb_links as $breadcrumb_link)
        {
            $breadcrumb .= ' > ' . $breadcrumb_link;
        }
        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);
        //echo $breadcrumb;



CPG Link: http://www.superstarparents.com/gallery_ss3/index.php?cat=8
(you'll see the default ">" in between "Public Galleries" and "Hillside...")

Page showing yellow arrow in a different breadcrumb: http://www.superstarparents.com/index/home.php
(top center between "SuperStar Parents" and "Index")

Title: Re: Possible to change the " > " in breadcrumb path
Post by: Tranz on January 26, 2006, 08:57:22 AM
Replace this with the corresponding one in your copy:

        foreach ($breadcrumb_links as $breadcrumb_link)
        {
            $breadcrumb .= ' <IMG src="/images/icons/arrw_y.gif" width="6" height="7" border="0" alt="arrw_y.gif" title=""> ' . $breadcrumb_link;
        }
        foreach ($BREADCRUMB_TEXTS as $BREADCRUMB_TEXT_elt)
        {
            $BREADCRUMB_TEXT .= ' >  ' . $BREADCRUMB_TEXT_elt;
        }
        // We remove the first ' > '
        $breadcrumb = substr_replace($breadcrumb,'', 0, 95);


The key part was where it says to remove the first ' > '. Since the img tag is 95 characters, that's the number needed to remove the extra img code.
Title: Re: Possible to change the " > " in breadcrumb path
Post by: Gephri on January 26, 2006, 09:47:20 AM
Thanks so much for the help.

For anyone else following along for fun - you should probably also change the line that follows the updated coding from


        $BREADCRUMB_TEXT = substr_replace($BREADCRUMB_TEXT,'', 0, 3);

to


        $BREADCRUMB_TEXT = substr_replace($BREADCRUMB_TEXT,'', 0, 95);

Title: Re: Possible to change the " > " in breadcrumb path
Post by: Tranz on January 26, 2006, 04:26:46 PM
Do you see a difference when modifying the $breadcrumb_text -related code? I don't see any difference that's obvious so I changed the code back in my example.
Title: Re: Possible to change the " > " in breadcrumb path
Post by: Gephri on January 27, 2006, 12:05:37 AM
I did not detect a difference - but I did not look across all possible locations that it could show up.

I took a 'best guess' that it should probably match the line above.

If i run into any prob's - I'll post here.