WordPress Hosting Tutorial :: How To Make Breadcrumb Without Plugin?

 

Breadcrumbs or breadcrumb trails are a graphical control element used as a navigational aid in user interfaces. It allows users to keep track of their locations within programs, documents or websites. The term comes from the trail of bread crumbs left by Hansel and Gretel in the eponymous fairytale.

Breadcrumb is used to facilitate navigation blog for readers, so readers know where they’re at page read, read articles related to any category. besides breadcrum can also be used as a link to return to class or to the home page. Although it looks simple breadcrumb also has great benefits for seo, because with breadcrumb also more keywords scattered on our website, making it easier to index articles in the SEO of our website. Breadcrumbs arrangement usually looks like this:
Home> Name Category> Title Posts

HOW TO MAKE BREADCRUMB WITHOUT WORDPRESS PLUGINS?

In this article, I will explain the tutorial, so if you want to create a breadcrumb without using plugins you can practice, but if you want more easily with plugins you can directly download on wordperss.

Steps to create a breadcrumb without plugins as follows:

  • Open the file in the folder Fungtions.php template you use, and then add the following script in function.
    echo ‘<ul id=”crumbs”>';
    if (!is_home()) {
    echo ‘<li><a href=”‘;
    echo get_option(‘home’);
    echo ‘”>';
    echo ‘Home';
    echo “</a></li>”;
    if (is_category() || is_single()) {
    echo ‘<li>';
    the_category(‘ </li><li> ‘);
    if (is_single()) {
    echo “</li><li>”;
    the_title();
    echo ‘</li>';
    }
    } elseif (is_page()) {
    echo ‘<li>';
    echo the_title();
    echo ‘</li>';
    }
    }
    elseif (is_tag()) {single_tag_title();}
    elseif (is_day()) {echo”<li>Archive for “; the_time(‘F jS, Y’); echo'</li>';}
    elseif (is_month()) {echo”<li>Archive for “; the_time(‘F, Y’); echo'</li>';}
    elseif (is_year()) {echo”<li>Archive for “; the_time(‘Y’); echo'</li>';}
    elseif (is_author()) {echo”<li>Author Archive”; echo'</li>';}
    elseif (isset($_GET[‘paged’]) && !empty($_GET[‘paged’])) {echo “<li>Blog Archives”; echo'</li>';}
    elseif (is_search()) {echo”<li>Search Results”; echo'</li>';}
    echo ‘</ul>';
    }
  • ¬†Once you have finished adding in the next function.php place the following script where you want to present it, either on or in the header.php single.php, adjust your template, of course, this tutorial will show you a simple breadcrumb.

 

HostForLIFE.eu revolutionized hosting with Plesk Control Panel, a Web-based interface that provides customers with 24×7 access to their server and site configuration tools. Plesk completes requests in seconds. It is included free with each hosting account. Renowned for its comprehensive functionality – beyond other hosting control panels – and ease of use, Plesk Control Panel is available only to HostForLIFE’s customers. They offer a highly redundant, carrier-class architecture, designed around the needs of shared hosting customers.