How to Insert Breadcrumbs in Wordpress

104 12

    Use a Plugin

    • 1). Log in to your blog dashboard and click on "Plugins" in the left navigation menu.

    • 2). Click the "Add New" button and on the next screen type "breadcrumb" --- without the quotation marks --- into the search box. Click "Search Plugins."

    • 3). Click the "Install Now" link under the plugin you want to use. Popular plugins are Breadcrumb NavXT and Yoast Breadcrumbs. Click "OK" when asked "Are you sure you want to install this plugin?" Click "Activate Plugin" to finalize the installation.

    • 4). Click "Editor" under "Appearance" in the left navigation bar to add the plugin code to the template. Click on "Header" in the right menu to add breadcrumbs below the header banner.

    • 5). Copy and paste the code from the plugin site into the header.php file where you want the breadcrumbs to appear on your blog. For example, to use Breadcrumb NavXT add the following code to your template:

      <div>

      <?php

      if(function_exists('bcn_display'))

      {

      bcn_display();

      }

      ?>

      </div>

    • 6). Click "Update File" to save your changes.

    Add Code

    • 1). Log in to your WordPress dashboard and navigate to the theme "Editor" under "Appearance" in the left navigation menu.

    • 2). Click on the file "functions.php" in the list of theme files on the right.

    • 3). Scroll to the end of the file and copy and paste the following code above the final "?>", starting on a blank line:

      function the_breadcrumb() {

      global $post;

      echo '<a href="/links/?u=';

      echo get_option('home');

      echo '">';

      bloginfo('name');

      echo "</a> » ";

      if ( is_category() || is_single() ) {

      the_category(' & ');

      if ( is_single() ) {

      echo " » ";

      the_title();

      }

      }

      if ( is_page() && $post->post_parent ) {

      echo 'post_parent) . '">';

      echo get_the_title($post->post_parent) . ";

      echo " » ";

      }

      if ( is_page() ) {

      echo the_title();

      }

      }

    • 4). Click "Update File" to save your changes.

    • 5). Click on "header.php" in the list of files on the right to add the breadcrumb function to your theme.

    • 6). Enter the following code in the template, where you want the breadcrumbs to appear:

      <?php the_breadcrumb(); ?>

    • 7). Click "Update File."

Subscribe to our newsletter
Sign up here to get the latest news, updates and special offers delivered directly to your inbox.
You can unsubscribe at any time

Leave A Reply

Your email address will not be published.