How To Add Breadcrumbs In Thesis Without Plugins

A breadcrumb trail is a set of links that can help a user understand and act as navigation aid to user. It increases the usability of your website. Breadcrumbs give visitors an alternative method of navigation, allow them to see where they stand in your website. They can see the category where your post is located. If the visitors find that post helpful he/she may want to see the other post in that category. It is placed typically horizontally across the top of a web page, below title bars or headers, like this:
Home page > Category > Post title

Breadcrumb Navigation

Why you need to use Breadcrumbs:

There are a lot of reasons why a webmaster have to use Breadcrumbs. Also many disagree them.  It allows the visitor to freely move within your site’s. It also easier for them to track their location on the website. It is easy to Easy to Backtrack if you enabled breadcrumbs. It can low down your bounce rate in a great number as visitors get chance to visit other category. It has a great impact on SEO.

How To  Add Breadcrumbs In Thesis:

There are a lot of plugins to  Add Breadcrumbs In Thesis. But if you use a lot of plugins it mnay slow down your website. As the Thesis is a great SEO optimized theme, you can  Add Breadcrumbs In Thesis with out a plugin. So lets see this

Step 1: Copy the below code to your custom_functions.php file. Make sure to keep a backup of file.

 

function thesis_breadcrumbs() {
	echo '<a href="';
	echo get_option('home');
	echo '">';
	bloginfo('name');
	echo "</a>";
		if (is_category() || is_single()) {
			echo "&nbsp;&nbsp;&#187;&nbsp;&nbsp;";
			the_category(' &bull; ');
				if (is_single()) {
					echo " &nbsp;&nbsp;&#187;&nbsp;&nbsp; ";
					the_title();
				}
        } elseif (is_page()) {
            echo "&nbsp;&nbsp;&#187;&nbsp;&nbsp;";
            echo the_title();
		} elseif (is_search()) {
            echo "&nbsp;&nbsp;&#187;&nbsp;&nbsp;Search Results for... ";
			echo '"<em>';
			echo the_search_query();
			echo '</em>"';
        }
    }
function display_breadcrumbs() {
?><div class="breadcrumbs"><?php thesis_breadcrumbs(); ?></div><?php
	}

add_action('thesis_hook_after_header','display_breadcrumbs');

 

Step 2: Now copy the below code to custom.css. You can modify as you like.

 

.custom .breadcrumbs {
	font-family:Verdana,Arial;
	font-size:1.2em;
	padding:1.2em 1em 1em 1em;
	border-bottom:1px #666;
	border-top:1px  #666;
}
.custom .breadcrumbs a {
	color:#cc0000;
	border-bottom:1px #fff;
}
.custom .breadcrumbs a:hover {
	border-bottom:1px #cc0000;
}

 

Step 3: You are done !  Save the file.

BAckup CoDE

Check Also

How To Add Facebook “Like” Button To Each Post In Thesis Without Plugin

Facebook is currently the most popular social networking site available. it bears an great importance …

Leave a Reply

Your email address will not be published. Required fields are marked *

*