Textpattern Forum

You are not logged in. Register | Login | Help

#51 2012-02-26 20:37:39

FireBot
New Member
Registered: 2012-02-26
Posts: 4

Re: [plugin] [ORPHAN] etz_crumbs

Hopefully this is the correct area to ask something like this. I’m fairly new to TextPattern and having a hard time figuring this out.

On this page ( http://www.polyworld.com.au/1-products/?c=poly-trolys ), I have the following code creating bread crumbs:

<div id="breadcrumbs"><txp:etz_crumbs hometitle="Home" separator=" &nbsp; :: &nbsp; " category="1" expand="1" /></div>

The problem is, Products is being shown twice in the breadcrumb trail (I would like it to only show once). I can’t figure out how to stop that from happening. I’m guessing it has something to do with the way categories are setup?

The category structure looks something like this:

-Products
—Material Handling
—-Poly Troly’s

I appreciate any help with getting this straightened out, preferably without needing to restructure all the categories.

Offline

#52 2012-02-26 23:20:56

uli
Moderator
From: Cologne/Köln
Registered: 2006-08-15
Posts: 3,142

Re: [plugin] [ORPHAN] etz_crumbs

I think the reason for the duplication is that the top level category has the same title as the section (I’m not a user of etz_crumbs, just had a look at the options in the first post). So you’d have to remove one of these. Try using the following code:

<div id="breadcrumbs">
   <txp:if_section name="1-products">
      <txp:etz_crumbs hometitle="Home" separator=" &nbsp; :: &nbsp; " category="1" expand="1" section="0" />
   <txp:else />
      <txp:etz_crumbs hometitle="Home" separator=" &nbsp; :: &nbsp; " category="1" expand="1" />
   </txp:if_section>
</div>

In case there are more duplications of top level category and section title, you could put the section title behind the first one into the if_section tag and separate them by a comma.
You could also try whether etz_crumbs supports wraptag and class (i.e. try removing the divs and use wraptag="div" class="breadcrumbs" inside the crumb tags), so you won’t get an empty div in case there is no breadcrumb displayed.

At the moment both section and top level category links lead to empty pages, BTW.

Welcome to the forum!


In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links

Offline

#53 2012-02-29 06:17:02

FireBot
New Member
Registered: 2012-02-26
Posts: 4

Re: [plugin] [ORPHAN] etz_crumbs

That did the trick, thank you! The options make a little more sense now, too. I pretty much dove head first into this project to help someone out. So I’m a bit over my head when it comes to the finer points. So you’ll probably be seeing more of me on the forums!

Offline

Board footer

Powered by FluxBB