簡體   English   中英

如何在tt_news LIST中強制使用模板文件?

[英]How force a template file in tt_news LIST?

我在tt_news中有一個列表,並使用許多包含tt_news記錄的文件夾。 過濾並顯示特定類別時,我想在此列表中使用其他模板。

我的打字稿是:

[globalVar = GP:tx_ttnews|place|0 = 79]
    #Display list of specific category   
    plugin.tt_news.templateFile = fileadmin/templates/plugins/tt_news/different.html
[else]
    #General display list
    plugin.tt_news.templateFile = fileadmin/templates/plugins/tt_news/general.html
[end]

我使用了plugin.tt_news.templateFileplugin.tt_news.file.templateFile但是不起作用。 我正在使用tt_news和TYPO3 6.2的最新版本

plugin.tt_news.templateFile ”是正確的,我認為“ [globalVar = GP:tx_ttnews|place|0 = 79] ”中存在問題,您應該使用“ [global] ”而不是“ [end] ”關閉全局。 如果對您有幫助,請嘗試此操作。

對於Typoscript方式沒有解決此問題,我為什么不這樣做? 對於我們,我們需要在tt_news模板中使用類別和標記,並通過JS在前端創建邏輯來解決此問題。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM