2015-04-01 75 views
1

流體的資產,很容易通過使用視圖助手創建一個URI指向資產提供:鏈接到與Typo腳本

{f:uri.resource(resource: asset.resource)} 

但我怎麼可以創建Typo腳本的鏈接或URI?

回答

0

在TypoScript中,可以使用TYPO3.TypoScript:Tag對象創建任何HTML標記。該資產是用一個Eel表達式引用的。在下面的示例中,資產標識符取自資產屬性,但也可以使用資源的UUID。

要創建URI,應用convertUris處理器。

myLinkTag = TYPO3.TypoScript:Tag { 
    tagName = 'a' 
    attributes.href = ${'asset://' + node.properties.asset.resource} 
    [email protected] = TYPO3.Neos:ConvertUris 
    content = 'My link text' 
}