2014-09-23 65 views
0

我想顯示子網站的內容並將其包裝在特定的div中。這是我的代碼:Typoscript:Wrap內容元素

lib.content = CONTENT 
lib.content { 
    stdWrap.wrap = <div id="sub-content-scroll">|</div> 
    renderObj.stdWrap.wrap = <div class="page">|</div> 
    table = tt_content 
    select { 
    pidInList.cObject < lib.allPid 
    where = colPos = 0 
    orderBy = pid 
    }  
} 

我的問題是:如何包裝唯一的每個pid。現在它將所有內容元素都包含在頁面div中。但我想通過網站實現包裝。 PS:lib.allPid是帶有ID的kommaseparated列表。

有人可以幫助我嗎?

非常感謝您的回答

我解決我的問題 Coreblade

+0

你可以用'科Frame'此:http://typo3.org/documentation/代碼段/ SD/38 / – Adrian 2014-09-23 10:33:26

回答

0

感謝。解決的辦法是實現一個雙方(lib.content和lib.allPid):

lib.content = HMENU 
lib.content { 
    stdWrap.wrap = <div id="sub-content-scroll">|</div> 
    special = directory 
    special.value = 7 
    1 = TMENU 
    1.NO { 
    doNotLinkIt = 1 
    field = uid 
    stdWrap.cObject = CONTENT 
    stdWrap.cObject { 
     wrap = <div class="page">|</div> 
     table = tt_content 
     select { 
     pidInList.field = uid 
     where = colPos = 0 
     orderBy = pid 
     } 
    } 
    } 
} 

Ragards Coreblade