WordPress.org

Ready to get started?Download WordPress

Forums

Hansel & Gretel: Fine-Tuned Breadcrumb Generator
[resolved] Customizing Breadcrumb Output for Current Item (2 posts)

  1. SolidSnake2003
    Member
    Posted 1 year ago #

    Your plugin is awesome. I do have a question though, is there a way that I can customize the current item?

    The reason I ask is I'm giving my breadcrumb the look of the original vBulletin forum bread crumb which looks like this:

    Home IMG sep Forums IMG sep Sub-Forum
    Current IMG Current Item

    Is it possible to create this look with your plugin?

    http://wordpress.org/extend/plugins/hansel-gretel/

  2. Chris
    Member
    Plugin Author

    Posted 1 year ago #

    Howdy,

    Thanks for the kind words, and we're glad you like H&G! I'm not sure I fully understand what you're asking for here, but if you specify the crumb_element and last_class or last_id, you can customize (via CSS or a JS library like jQuery) the last crumb however you want:

    HAG_Breadcrumbs(array(
      'crumb_element' => 'span',
      'crumb_class' => 'last'
    ));

    And in your CSS:

    #breadcrumbs .last:before {
      content: '';
      width: 16px;
      height: 16px;
      background: (path/to/my/image.png) no-repeat;
    }

    Or if you need it to work in old IE, you might use JS instead (a la jQuery):

    jQuery(function($) {
      var $img = $('<img/>', { src: 'path/to/my/image.png' });
      $('#breadcrumbs .last').prepend($img);
    });

    Let me know if this is what you were looking for or if you need something different. We're currently working on adding action/filter hooks so you can manipulate the crumbs as they are generated (the text/link/etc...) as well as their order before being outputted. That might be a solution that is better suited to your needs.

    Let us know!

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic