<@cms_file>

File content tags

Tag Name

<@cms_file>

Tag Description

Obtain a list of file content details, use ${Data.intro} Obtain content details data

Tag attributes

AttributeTypeRequiredAvailable valuesDescriptionDefault
contentIdINTEGERYes Content ID
pageBOOLEANNotrue = Yes
false = No
Do we need to use pagination?false

Tag data attributes

AttributeDescriptionType
fileSizeFile size, unit: bytesLong
introFile IntroductionString
pathFile resource pathString
typeFile typesString

Usage Examples

Content detail page displays file information.

<!-- File Content Title -->
<h1>${Content.title}</h1>

<@cms_file contentid="${Content.contentId}">
<!-- File description -->
<dl>
  <dt>File Type:${Data.type!'Unknown'}</dt>
  <dt>File Size:${Data.fileSize!'-'}</dt>
</dl>
<div class="file-intro">
${dealArticleBody(Data.intro)}
</div>
<!-- Download link -->
<div class="download">
  <a href="${Data.link}"
</div>
</@cms_file>

On this page