The news breadcrumb

A good breadcrumb does not wrap a link about the currently active item.
Is there any way to unlink the news index breadcrumb? Any other function I can use for that instead of `printNewsIndexURL()`

Index[link] » News [link] » My second page [no-link]

Index[link] » News [no-link]

`


" title="<?php gettext('Index'); ?>"><?php echo gettext("Index"); ?> »
<?php printNewsIndexURL(gettext('News')); ?>

<?php printZenpageItemsBreadcrumb(' » ',''); printCurrentNewsCategory(" » "); ?>
<?php printNewsTitle(" » "); printCurrentNewsArchive(" » "); ?>

`

Comments

  • Uhm? how about `gettext('news')`????
  • I'm not sure what the issue is, the default breadcrumb from zenpage theme does just that. What theme are you using?

    Here's the default zenpage breadcrumb for the image page:
    `

    `
    If you refer to the default zenpage theme it does exactly what you're asking for.
  • @ sbillard when I use `gettext('news')` it's what I want on the News index page, but there is no link wrapped around it when I go one level deeper.

    @ micheall it does that for the Image pages yes but not for News. I checked all other themes that ship with ZP and all of them wrap a link on around the News index.
    The `printParentBreadcrumb()` function says:
    Prints the breadcrumb navigation for album, gallery and image view

    So not for News..
  • acrylian Administrator, Developer
    The gallery index url link is added statically before it. If you don't want it you can add an if/else to disable the link to just print "news". The link generally servers as the "news index" link (news page 1 link) so you can easily jump to the first page for futher ones.
  • Ah it's not easy to explain but I think you got me acrylian.
    An if/else statement is exactly my thought.. but how?
    How can I state we are on the index page?

    `
    if (this_page_is_the_news_index) {
    echo "" . gettext('News') . "";
    } else {
    printNewsIndexURL(gettext('News'));
    }
    `
  • acrylian Administrator, Developer
    Try
    `if(is_NewsPage() && !is_NewsArticle() && !is_NewsCategory()) { ... ) else { ... }`
  • Aha! That will work.
    Great. Thanks acrylian!
Sign In or Register to comment.