2015-10-01 39 views
1

我試圖顯示當前頁面的類別。
因爲我在TYPO3中不太好,所以我第一次試圖在顯示當前之前嘗試顯示全部之一。
以下代碼片段無法正常工作。TYPO3 7.4顯示類別

lib.categorized_content = RECORDS 
lib.categorized_content { 
    categories.field = selected_categories 
    categories.relation.field = category_field 
    tables = tt_content 
    conf.tt_content = TEXT 
    conf.tt_content { 
     stdWrap.field = header 
     stdWrap.typolink.parameter = {field:pid} 
     stdWrap.typolink.parameter.insertData = 1 
     stdWrap.wrap = <li>|</li> 
    } 
    wrap = <ul>|</ul> 
} 

這是我從這個片段:https://docs.typo3.org/typo3cms/TyposcriptReference/ContentObjects/Records/Index.html#categories

我使用<f:cObject typoscriptObjectPath="lib.categorized_content" />落實到我的模板。

有人可以幫忙嗎?

+0

categories.field = 1,3 [categories UIDs]而不是categories.field = selected_categories and categories.relation.field = actual_field_name like uid而不是categories.relation.field = category_field –

回答

1

selected_categoriescategory_field是柔性成型字段從Special Menu內容元素(如可以從配置屬性的後綴.field看到)。 您必須將其替換爲實際值。