[7.1] Removing Breadcrumb Redundancy - 03/01/2007 1:57 PM
When viewing a forum or sub-forum, it really bothered me to see the name of the forum I was in repeated twice in the breadcrumb - first as a link, second as plain text.
Instinctively, whenever I wanted to go up one level (the mouse-click equivalent of 'cd ..') I would always click on the second last segment in the breadcrumb, but when you had a breadcrumb that looked like:
site >> Forums >> Foo >> Foo
you'd wind up in the same forum again. This reeeeaallly annoyed me, so here's a little mod that removes the redundant forum name from the breadcrumb.
In libs/ubbthreads.inc.php, find:
and change to:
So now, when viewing a forum, you get:
site >> Forums >> Foo
and when viewing a thread, you get:
site >> Forums >> Foo >> Thread Title
as it should be!
Instinctively, whenever I wanted to go up one level (the mouse-click equivalent of 'cd ..') I would always click on the second last segment in the breadcrumb, but when you had a breadcrumb that looked like:
site >> Forums >> Foo >> Foo
you'd wind up in the same forum again. This reeeeaallly annoyed me, so here's a little mod that removes the redundant forum name from the breadcrumb.
In libs/ubbthreads.inc.php, find:
Code
if ($inputTitle) {
$breadcrumb .= " » $inputTitle";
}
Code
if ($inputTitle != $forum_title) {
$breadcrumb .= " » $inputTitle";
}
So now, when viewing a forum, you get:
site >> Forums >> Foo
and when viewing a thread, you get:
site >> Forums >> Foo >> Thread Title
as it should be!