I am trying to remove the breadcrumb from the homepage (Home link). I am using a bartik theme. I have a page--front.tpl.php and have tried removing the following code snippets and clearing the cache, but the Home breadcrumb is still there. Any help would be greatly appreciated

<?php if ($logo): ?>
  <a href="<?php print $front_page; ?>" title="<?php print t('Home'); ?>" rel="home" id="logo">
    <img src="<?php print $logo; ?>" alt="<?php print t('Home'); ?>" />
<?php endif; ?>


<?php if ($breadcrumb): ?>
  <div id="breadcrumb"><?php print $breadcrumb; ?></div>
<?php endif; ?>

Edit: I just realised that my front page isn't actually picking up the page--front.tpl template. Why might this be??? :(

  • visit in appearance page once and clear the cache. If you are adding theme related function and template, Please do the above step. – Ramesh Babu T B May 27 '13 at 9:42

Another solution could be the Disable breadcrumbs module. The pros of the modules are that writing code is not necessary and it is independent from the theme; in this way, you don't need to alter the theme each time you change the theme being used.

Disable breadcrumbs on a per node, per content type, or by path (any path) basis; Omitting the need to write additional code in the theme layer (template.php file etc..) to determine the visibilty of breadcrumbs on specific pages. This can be administered on node edit forms and from the content administration page (node operations) to select/unselect multiple nodes for enabled types.


You can also comment them out on the page.tpl.php like so

<?php /* if ($breadcrumb): ?>
       <div id="breadcrumb"><?php print $breadcrumb; ?></div>
   <?php endif; */?>

And then if you want them back later... take the /* s out. :)

  • This would be for the entire tho... – Mwow Nov 22 '13 at 1:53
  • comment on if condition will not hide the breadcrumb – Bala Nov 22 '13 at 3:01

You can also use this code.

if (!$is_front && !empty($breadcrumb)) {
  print $breadcrumb; 

Otherwise, go to your theme folder and remove the code in page.tpl.php. This will be remove the breadcrumbs from your site.

Be careful: It will completely remove the breadcrumbs. If you want to get them back later, then keep the code in another file.

This is the code for the Bartik theme.

<?php if ($breadcrumb): ?>
  <div id="breadcrumb">
    <?php print $breadcrumb; ?>
<?php endif; ?>

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.