[TYPO3] How to (sensibly) crop entire breadcrumb menu

Paul Vetch paul at qedstudio.com
Tue Jul 4 14:12:34 CEST 2006


Hi Peter,

Many thanks for this (the second time you've rescued me recently!)

I had assumed that HMENU wouldn't be possible - this gives me a really
helpful starting point, thanks very much.

I think (though I may be alone!) this would be useful functionality for
HMENU actually - some sort of global crop function maybe?

menucrop = * | ... | *
menucrop.threshold = 5,120
menucrop.showlevels = 1|2

 - so you could specify the number of items to appear before and after
the crop, and the number of entries or characters which would trigger
the crop.

Or, maybe I'm the only person who's ever needed this functionality ;)

Best wishes

Paul









-----Original Message-----
From: Peter Klein [mailto:peter at umloud.dk] 
Posted At: 04 July 2006 08:56
Posted To: typo3.english
Conversation: [TYPO3] How to (sensibly) crop entire breadcrumb menu
Subject: Re: [TYPO3] How to (sensibly) crop entire breadcrumb menu

Hi Paul. That's not possible using HMENU/special = rootline, but you can

create a pseudo breadcrumb menu using plain TEXT objects, and
CONDITIONS..

Here's an example:

-- cut --
lib.pseudocrumbs = COA
  # Current page
  100 = TEXT
  100.data = leveltitle:-1
  100.typolink.parameter.data = leveluid:-1
  100.wrap = | >
}
[treeLevel= 1,2,3,4]
  # Previous page
lib.pseudocrumbs.90 < lib.pseudocrumbs.100
lib.pseudocrumbs.90.data = leveltitle: -2
lib.pseudocrumbs.90.typolink.parameter.data = leveluid:-2
[GLOBAL]

[treeLevel=2,3,4]
  # Page before previous page
lib.pseudocrumbs.80 < lib.pseudocrumbs.100
lib.pseudocrumbs.80.data = leveltitle: -3
lib.pseudocrumbs.80.typolink.parameter.data = leveluid:-3
[GLOBAL]

[treeLevel=3,4]
  # Page before page before previous page
lib.pseudocrumbs.70 < lib.pseudocrumbs.100
lib.pseudocrumbs.70.data = leveltitle: -4
lib.pseudocrumbs.70.typolink.parameter.data = leveluid:-4
lib.pseudocrumbs.80.data >
lib.pseudocrumbs.80.value = ...
[GLOBAL]

[treeLevel=4]
  # Page before page before page before previous page
lib.pseudocrumbs.60 < lib.pseudocrumbs.100
lib.pseudocrumbs.60.data = leveltitle: -5
lib.pseudocrumbs.60.typolink.parameter.data = leveluid:-5
lib.pseudocrumbs.70.data >
lib.pseudocrumbs.70.value = ...
[GLOBAL]

-- cut -- 

-- 
Peter Klein/Umloud Untd


"Paul Vetch" <paul at qedstudio.com> skrev i en meddelelse 
news:mailman.1.1151914772.5579.typo3-english at lists.netfielders.de...
> Hi,
>
> I have a breadcrumb menu on a website with fixed width.  Because the
> site is pretty large (5 + levels deep) the breadcrumb nav occasionally
> gets too long, even though I'm already cropping the individual page
> titles quite a bit.  What I'd like to do is something along these
lines:
>
> Your path: Home > Section 1 > ... > Subsection > Current Page
>
> - so that, if the menu is say 4 levels long or more, or maybe if the
> total character count of the menu exceeds a set number, the middle
path
> entries just get written in as an ellipsis (...) or something similar.
>
> I suspect this will mean creating the menu in TS since I can't figure
> out how to do this with a rootline HMENU, but if anyone could give me
> any tips or has done something like this in TYPO3 it would be great to
> have something to start from...
>
> Cheers,
>
> Paul
>
>
> 






More information about the TYPO3-english mailing list