ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Autocrumb - Lightweight Breadcrumb Helper (ver.12.05.1)

December 09, 2009 5:58pm

Subscribe [78]
  • #46 / Apr 03, 2010 6:08am

    ardinotow

    162 posts

    @ToMix,
    From your url http://mysite.com/ci/admin/users_accounts with your replacer config it should have breadcrumb like: Home > Ci > Admin Area > Manage Users. With “ci” as part of url then it should also become a part of breadcrumb, how you remove “Ci” from breadcrumb? Do you use either $config[‘exclude’] = array(‘ci’) or $config[‘exclude_segment’] = array(1)?

  • #47 / Apr 03, 2010 6:23am

    ToMix

    5 posts

    Hi,

    I set this line :

    $config[‘set_home’] = “Home”;

    in my config file.

    so i got breadcrumb like: Home > Admin Area > Manage Users

    */*/*/*/*/*/

    if you mean why my url dose not looks like this:

    http://mysite.com/index.php/ci/admin/users_accounts

    i used (.htaccess) file to remove the (index.php) from the url ..

  • #48 / Apr 03, 2010 7:39am

    ardinotow

    162 posts

    ToMix, I also used .htaccess to remove index.php from url and that doesn’t affect in my breadcrumb helper.

    I still don’t understand how can “CI” [http://mysite.com/ CI /admin/users_accounts] as part of your URL not showing in breadcrumb

  • #49 / Apr 03, 2010 8:06am

    ToMix

    5 posts

    ardinotow

    mybe because this line in config/config.php:

    $config[‘base_url’]= “http://localhost/ci/”;

    could you help me and solve my problem @ this post http://ellislab.com/forums/viewreply/733791/

    please, 😊

  • #50 / Apr 04, 2010 11:22am

    ardinotow

    162 posts

    ToMix, please try the new update. Let me know if this can’t solve your problem.

  • #51 / Apr 04, 2010 11:27am

    ardinotow

    162 posts

    ** Breadcrumb Helper 4.10.1 **

    Bug fixed:
    1. Sometimes the replacer only replace the value of last segment.

    Enjoy,
    Ardinoto

  • #52 / Apr 05, 2010 4:34am

    ToMix

    5 posts

    ardinotow,

    Very Exelent.

    Your last Update {Breadcrumb Helper 4.10.1} works successfully.

    My probelm solved , Thank you very much.

  • #53 / Apr 05, 2010 9:46am

    ardinotow

    162 posts

    ardinotow,

    Very Exelent.

    Your last Update {Breadcrumb Helper 4.10.1} works successfully.

    My probelm solved , Thank you very much.

    You’re welcome 😊

  • #54 / Apr 13, 2010 11:09pm

    -Gareth

    4 posts

    This is great! EXACTLY what I wanted!
    Thanks.

    Actually, it’s not exactly what I need. I’m creating a forum, and so on topic pages, for example I have the url:

    http://localhost/topic/view/12/gasdfa

    It produces the breadcrumbs:

    Home
    Topic
    gasdfa

    which is good. However, I know I can rename Topic to Category, but two things:

    1) Can I change the link that Topic/Category links to (such as it now links to localhost/topic but can I have it to localhost/category-of-topic, I’ll need to pass in a variable here) ?
    2) How can I pass in a variable to change Topic to the correct category name (such as News and Announcements)?

    Because the config is in config/ not a controller, I cannot do any logic on it!

    Edit: I would like this to happen:

    Home
    News And Announcements (with correct link) - this can be decided by logic
    gasdfa

  • #55 / Apr 15, 2010 10:19am

    ardinotow

    162 posts

    Hi -Gareth,

    I think your request can be done without modifying the breadcrumb helper. You can change your url to be more SEO friendly (also autoCRUMB friendly) like this: http://localhost/topic/view/news-and-announcement/gasdfa. What do you think?

  • #56 / Apr 15, 2010 5:39pm

    -Gareth

    4 posts

    That is a possibility, however I’d still like to have it as I did…
    Are there any other possibilities? I’m not particularly happy having both the category and topic names in the url..

  • #57 / Apr 16, 2010 12:57am

    ardinotow

    162 posts

    Gareth,
    I think you can try this:
    1. Find this line in breadcrumb_helper

    function set_breadcrumb($delimiter = '', $exclude = '')
    change to
    function set_breadcrumb($mod_uri = '', $delimiter = '', $exclude = '')

    2. Find this line in breadcrumb_helper

    $uri = rtrim($CI->uri->uri_string(),'/');

    change to

    if ($mod_uri)
    {
       $uri = rtrim($mod_uri,'/');
    }
    elseif ( ! $mod_uri)
    {
       $uri = rtrim($CI->uri->uri_string(),'/');
    }

    3. Now, in your page where you want to show breadcrumb, change standard breadcrumb caller like

    <?php echo set_breadcrumb(); ?>

    to

    <?php 
       $mod_uri = "/your/new_url_link/for_breadcrumb"; // exclude base url
       echo set_breadcrumb($mod_uri); 
    ?>

    You can also parse $mod_uri from your controller so you can do any logic on it. Hope that works. I don’t have time to try those code from my localhost, so please let me know the result.

  • #58 / Apr 26, 2010 4:26pm

    ElToro

    16 posts

    Thx for the nice Helper!

    Could there be possible to use arrays in replace to make two out of one?

    Like this

    URL: mysite.com/category_listing 
    CRUMBS: Home > Categorys
    URL: mysite.com/category
    CRUMBS: Home > CategorysListing > Category
    URL: mysite.com/category/item
    CRUMBS: Home > CategorysListing > Category > Item

    by using

    $config['replace'] = array('category' => array('category_listing' => Categorys, 'category' => 'Category'));

    Well lets see if I have time to hack.

  • #59 / Apr 30, 2010 11:35am

    ardinotow

    162 posts

    @ElToro,
    Feel free to hack it 😊

  • #60 / May 01, 2010 5:27am

    ElToro

    16 posts

    Ok, I had some time to play around with it.. and it is done. I still need to figure out how I can send merge request or something like in from windows hg client.

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases