...
Note |
---|
external_link_list_url is populated with the contents of the site overview tree by default. |
InsertHTML Templates
The related media content (for example, images, files and html pages) that have been configured for the rich text editor will look for the presence of templates prefixed with "inserthtml" (lowercase is required for case-sensitive operating systems). These are little mini templates that can be used to insert a special chunk of HTML with properties from the relevant content type selected.
By default, if there are no "inserthtml" files inside your webskin folders, then you do not see a dropdown under the tab for the relevant content type. Remember, the "@@displayname:" line determines what the user sees in the dropdown so make this descriptive and relevant.
Sample dmImage template
Code Block | ||
---|---|---|
| ||
<!--- @@displayname: Image and caption --->
<cfoutput>
<p class="featurepic">
<img src="/images/#stObj.imagefile#" alt="#stObj.alt#" /><br />
#stObj.alt#
</p>
</cfoutput>
|
Sample dmFile template
This example uses the FncFileSize cflib.org function
Code Block | ||
---|---|---|
| ||
<!--- @@displayname: Full file link --->
<!--- include FncFileSize function here; omitted for brevity --->
<cfif application.config.general.fileDownloadDirectLink eq "false">
<cfset theURL = "#application.url.webroot#/download.cfm?DownloadFile=#stObj.ObjectID#">
<cfelse>
<cfset theURL = "#application.url.webroot#/files/#stObj.filename#">
</cfif>
<cfoutput>
<a class="file-#LCase(stObj.fileExt)#" href="#variables.theURL#" target="_blank" title="#stObj.description#">#stObj.title# [#UCase(stObj.fileExt)# #FncFileSize(stObj.fileSize)#]</a>
</cfoutput>
|