MyBB Community Forums

Full Version: Some Little Hacks/Tricks With Bread Crumbs!
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Some Little Hacks/Tricks With Bread Crumbs! :

How to change the first breadcrumb from Forum Index to Home :

You need to edit the "Global.php" from the root.

Find this:
$navbits = array();
$navbits[0]['name'] = $mybb->settings['bbname_orig'];
$navbits[0]['url'] = $mybb->settings['bburl']."/index.php";

& then change it to:
$navbits = array();
$navbits[0]['name'] = 'Home' ;
$navbits[0]['url'] = $mybb->settings['bburl']."/index.php";

How to remove the Category name when viewing any thread:

You are going to do this:
Index -> Category -> Forum -> Viewing Thread

To:
Index -> Forum -> Thread

You need to remove the following line from ./inc/functions.php around line 3300.
if($pforumcache[$forumnav['pid']])
                {
                    build_forum_breadcrumb($forumnav['pid']);
                } 


How to change the link of "Index.php" from the first breadcrumb:

Again edit "Global.php" & edit
$navbits = array();
$navbits[0]['name'] = $mybb->settings['bbname_orig'];
$navbits[0]['url'] = $mybb->settings['bburl']."/index.php";

To:
$navbits = array();
$navbits[0]['name'] = $mybb->settings['bbname_orig'];
$navbits[0]['url'] = 'http://yourlink.com' ;

I hope these little tricks will help you bit.
& then change it to:
Code:
$navbits = array();
$navbits[0]['name'] = 'Home' ;
$navbits[0]['url'] = $mybb->settings['bburl']."/index.php";

Can you show me away to have a home ".png' or '.gif. icon for Home in the breadcrumbs?
(2014-11-10, 09:40 AM)AmatureDJ Wrote: [ -> ]Can you show me away to have a home ".png' or '.gif. icon for Home in the breadcrumbs?

$navbits[0]['name'] = '<img src="'.$mybb->settings['bburl'].'/images/home.png" title="Home" alt="Home" />';

Upload home.png in the images folder
(2014-11-14, 07:31 PM)Mipher Wrote: [ -> ]
(2014-11-10, 09:40 AM)AmatureDJ Wrote: [ -> ]Can you show me away to have a home ".png' or '.gif. icon for Home in the breadcrumbs?

$navbits[0]['name'] = '<img src="'.$mybb->settings['bburl'].'/images/home.png" title="Home" alt="Home" />';

Upload home.png in the images folder

Thanks for the reply but where do i place this code?
Edit your global.php, around line 855:

Find:

$navbits[0]['name'] = $mybb->settings['bbname_orig'];

Replace with:

$navbits[0]['name'] = '<img src="'.$mybb->settings['bburl'].'/images/home.png" title="Home" alt="Home" />';
Why not
$navbits = array();
$navbits[0]['name'] = $mybb->settings['bbname_orig'];
$navbits[0]['url'] = $mybb->settings['bburl'];

Instead of

$navbits = array();
$navbits[0]['name'] = $mybb->settings['bbname_orig'];
$navbits[0]['url'] = 'http://yourlink.com';

Incase the forum admin later move the forum to another directory?
I am not sure why you have Home for it. You just replace the link

Ex: Community.mybb.com to Home.
(2014-11-29, 01:46 AM)Mipher Wrote: [ -> ]Edit your global.php, around line 855:

Find:


$navbits[0]['name'] = $mybb->settings['bbname_orig'];

Replace with:


$navbits[0]['name'] = '<img src="'.$mybb->settings['bburl'].'/images/home.png" title="Home" alt="Home" />';

Thanks.. That worked. Shy