Translations
Info
All page names need to be in English.
en da  de  fr  it  ja  km  nl  ru  zh

Content Slide

From TYPO3Wiki
Jump to: navigation, search

Content Sliding in TYPO3 >= 4.0.0

This article is about how to let a content-element "slide" through the rootline to the actual pages (this is for standard method only... not TV). This means that you insert a Content-Element for example in the Right-Column of your Root-Page and it gets inherited to all subpages.

If you place another Content-Element (CE) into the right column on one of the subpages this CE will substitute the element from the root-page and in this part of the page tree the later CE will get shown.

Note that content does not slide through Sysfolders.

This behvaiour is possible prior to TYPO3 4.0.0 by using the KB Content Slide extension. Since 4.0.0 this feature is integrated into the core. The core integrated version also supports a few other nifty features like "collecting" all elements till the rootpage and display them all together. It is also possible to give a count value how many levels T3 will try to "slide up". So you could for example always display the combined elements of this and the parent page.

Property reference

This are additional properties to the already existing ones for the cObj "CONTENT". This information will get added to TSref soon.

Property Data type Description Default
slide integer Enables content-sliding. Must get set to the amount of levels which shall get walked up the rootline. For infinite sliding (till the rootpage) set it to -1
slide.collect integer Enables collecting the found elements. Must get set of the amount of levels which shall get collected while walking up the rootline. For infinite collectin (till the rootpage) set it to -1. When you set collect and slide.collect both to a value different than -1 (you define an amount of levels) the lesser value will apply (if one is set to 2 and the other to 3 T3 will only walk 2 pages up the rootline)
slide.collectReverse boolean Normally when collecting content elements the elements from the actual page get shown on the top and those from the parent pages below those. You can invert this behaviour (actual page elements at bottom) by setting this flag
slide.collectFuzzy boolean Only useful in collect mode. When no content elements have been found for given depth in collect mode it

will traverse further till it finds at least something.

[tsref:(cObject).CONTENT]

Examples

Example 1

This first example simply enables content-sliding for the right-column wherever you use it:

styles.content.getRight.slide = -1

The second example enable also collecting of elements.

styles.content.getRight.slide = -1
styles.content.getRight.slide {
  collect = -1
  # collectReverse = 1
}

This example collects only the current and the parent page.

styles.content.getRight.slide = -1
styles.content.getRight.slide {
  collect = 2
  # collectReverse = 1
}

If you want more example or have a special requirement write a mail to me: kraftb@kraftb.at


Bernhard Kraft 14:30, 22 Mar 2006 (CET) [www.think-open.at]

Example 2

The above examples were too confusing for me this helped to understand it:

  sidebar < styles.content.getRight
  sidebar.slide = -1

(In Typo3 4.2 is this seemingly the only working Syntax.)


Szabolcs Feczak 13:30, 08 August 2007 (AU/Sydney) [nmi.rulez.org]

Content Sliding in TYPO3 3.8.x by TS only

temp.bildoben = COA
temp.bildoben {
  11 < styles.content.getLeft
  11.stdWrap.ifEmpty.cObject < styles.content.getLeft 
  11.stdWrap.ifEmpty.cObject {
stdWrap.ifEmpty.cObject < styles.content.getLeft
stdWrap.ifEmpty.cObject {
select.pidInList.data = leveluid:-3
}
select.pidInList.data = leveluid:-2
}
}
# then inset it like this
#....  marks.CONTENT_LEFT < temp.bildoben
#

Content Sliding in TYPO3 4.0 and TV 1.0

The content-slide feature integrated into 4.0.0 core does not support sliding for TemplaVoila.

TemplaVoila Content-Elements are handled differently than when using MTB method. In TV just CE's get shown which are inserted into the Flexform of the Page. No matter on which page they reside or which colPos they do have set.

And as TV is not part of the TYPO3 core it will not be the case that code which is used for TV get's integrated into the core.

So for those who are using TV you have to install TV Content Slide which works with the new TV.

...the Manual: http://typo3.org/extension-manuals/kb_tv_cont_slide/0.0.2/view/toc/0/