-1

I have a custom page set in Settings > Read > Articles Page (page named "Blog").

It's not my homepage, but NavXT breadcrumbs show only "Home". I'd like it to show the page title : "Home > Blog".

How can I achieve this?

  • If you set a blog page, this will be your homepage. is_home() will return true on this page. – Pieter Goosen Jan 8 '15 at 10:01
  • You're right, and for the real homepage it returns false (when it's a static page)... that's strange isn't it ? – theredled Jan 8 '15 at 13:03
  • Anyway what's the proper way to change breadcrumb in that case ? – theredled Jan 8 '15 at 13:05
  • I've voted for close this question because you are asking specifically how to modify the breadcrumb grnerated by third party plugin and don't accept answers about how to do it without that plugin. – cybmeta Jan 10 '15 at 9:04
1

It seems that you have a misunderstanding about a static front page and a blogpage and the returned result from the conditional tags. Here is a short explanation

STATIC FRONT PAGE

The general misconception is that your static front page is your home page, which it is not. The static front page is just a cover page, if you wish, something like the cover of a book. It serves the purpose of introducing someone to what the site/author/etc is all about

The static front page is in most cases used as an introductary/portfolio page with important info about the site/author/business/etc. The content on this page is static and usually only change if there are some changes to the site/author/business itself

The conditional tag is_home() returns false on this page, because as said, this is not the home page, but something like a cover page. The conditional tag is_front_page() should be used to test this page

BLOG PAGE

Popular misbelieve is that this is like a normal page on the site, while in fact this is the true home page of the site. This page is exactly the same as your normal homepage when no static front page is set. This page displays all your blog posts as normal

is_home() will return true on this page, as I said, because this is the actual homepage of the site. This is why you see the behavior as you have stated in your question.

GENERALISING

Plugin specific question is off topic here, so you should contact the plugin author for assistance with implementing this.

On a general note, you can also write yor own breadcrumb to modify the behavior of the output on your blogpage

If you need something like Home > Blog to display on your blog page, you can do the following conditional check inside your breadcrumb

if( is_home() && 'page' == get_option( 'show_on_front' ) ) {
    echo 'Home > Blog';
}elseif( is_home() && 'posts' == get_option( 'show_on_front' ) ) {
    echo 'Home';
}

Additional resources: Creating a Static Frontpage

| improve this answer | |
  • Thanks a lot for your answer, but as plugin support is off-topic here it doesn't answer to my question (targeting the right page being a minor sub-issue), so I can't accept it. – theredled Jan 9 '15 at 12:18

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.