content

The content tag inserts the requested content from the TD repository into the given page. If there is an error rendering the content to the page, the body of the tag will be displayed instead. If the content is empty, a boilerplate HTML snippet indicating an error is inserted.

This tag contains the following attributes:

addPageviewImage
Whether to automatically insert an HTML <img> tag after the rendered content that will request a 1x1-pixel, invisible image causing the server to record a view of this content. This will force a pageview to be recorded, even if the rendered page is served from a browser or other cache.
  • Required: false
  • Type: Boolean
  • Default: false
  • Since: 4.2
assembly
An whose content to render. One of this, 'url', or 'searchTerm' must be specified, and they are evaluated in that order.
  • Required: false
  • Type:
  • Default: None
assemblyTopicRef
If an assembly is specified, this is the ID of the topic within that assembly to render. If an assembly is specified without this attribute, the assembly map itself is rendered. this is specified without an assembly, it is ignored.
  • Required: false
  • Type: String
  • Default: None
contextKey
The context key. Overridden by contextUrl and/or contextUrlString and/or the context key specified in url/urlString, in that order.
  • Required: false
  • Type: String
  • Default: none
contextUrl
The of the context from which to load the data. Used to configure hyperlinks and image references in the resulting content.
  • Required: false
  • Type:
  • Default: none
contextUrlString
The of the context from which to load the data. Used to configure hyperlinks and image references in the resulting content.
  • Required: false
  • Type: String
  • Default: none
expandReferences
Whether to expand references to child documents. This is used to render all topics in a DITA Map-based publication on a single page.
  • Required: false
  • Type: boolean
  • Default: false
ignoreCache
Whether to go to the database, ignoring caches. Note that this will flush the requested data from the cache and re-cache the newly loaded version. Default is false.
  • Required: false
  • Type: boolean
  • Default: none
itemKey
The item key. Overridden by url and/or urlString.
  • Required: false
  • Type: String
  • Default: none
linkContext
This attribute is deprecated and can be ignored.
  • Required: false
  • Type: Boolean
  • Default: none
pipeline
Post-transform content processing can be accomplished with built-in content processing pipelines. Currently the only supported pipeline is "filterchain:/harp/portal/markFilteredTopics.xml", which can mark or remove links to topics not available in the portal, and requires pipelineParameters "portal" (), "contextKey" (), and "removeFilteredEntries", a boolean controlling whether to remove or simply mark links to filtered content.
  • Required: false
  • Type: String
  • Default: None
projectKey
The Project key. Overridden by url and/or urlString.
  • Required: false
  • Type: String
  • Default: none
recordPageview
Whether to record a pageview for the given content in the reporting system. This should only be true when viewing content in a custom portal page. The built-in content viewing pages all record the pageview before the response is rendered. But when rendering content on a custom portal page, this should be specified as true to ensure that the content view is recorded.
  • Required: false
  • Type: boolean
  • Default: false
searchTerm
A search term whose first result will be the rendered by this tag. Overrides url and contextUrl attributes. Required if url attribute not provided. Can be combined with metadata specified in metadataFilterTags.
  • Required: false
  • Type: String
  • Default: none
timeout
The amount of time, in ms, after which the transform may be cancelled. The default value is generally 60000 (60 seconds), though this can vary depending on the application's configuration. Set to 0 to disable timeouts, but do this with care; infinitely-running transforms can severely degrade application performance site-wide.
  • Required: false
  • Type: long
  • Default: 60000
  • Since: 4.2
url
The object describing the content to retrieve. Required if searchTerm attribute is not provided.
  • Required: false
  • Type:
  • Default: none
urlString
The object describing the content to retrieve. Required if searchTerm attribute is not provided.
  • Required: false
  • Type: String
  • Default: none
xsl
Relative path to an XSLT file, relative to the WEB-INF directory of the web application, to apply to the content. Parameters to the XSLT can be passed using nested xslParam tags.
  • Required: false
  • Type: String
  • Default: none

This tag contains the following attributes.

Name Description Required Type Default
addPageviewImage Whether to automatically insert an HTML <img> tag after the rendered content that will request a 1x1-pixel, invisible image causing the server to record a view of this content. This will force a pageview to be recorded, even if the rendered page is served from a browser or other cache. false Boolean false
assembly An whose content to render. One of this, 'url', or 'searchTerm' must be specified, and they are evaluated in that order. false None
assemblyTopicRef If an assembly is specified, this is the ID of the topic within that assembly to render. If an assembly is specified without this attribute, the assembly map itself is rendered. this is specified without an assembly, it is ignored. false String None
contextKey The context key. Overridden by contextUrl and/or contextUrlString and/or the context key specified in url/urlString, in that order. false String none
contextUrl The of the context from which to load the data. Used to configure hyperlinks and image references in the resulting content. false none
contextUrlString The of the context from which to load the data. Used to configure hyperlinks and image references in the resulting content. false String none
expandReferences Whether to expand references to child documents. This is used to render all topics in a DITA Map-based publication on a single page. false boolean false
ignoreCache Whether to go to the database, ignoring caches. Note that this will flush the requested data from the cache and re-cache the newly loaded version. Default is false. false boolean none
itemKey The item key. Overridden by url and/or urlString. false String none
linkContext This attribute is deprecated and can be ignored. false Boolean none
pipeline Post-transform content processing can be accomplished with built-in content processing pipelines. Currently the only supported pipeline is "filterchain:/harp/portal/markFilteredTopics.xml", which can mark or remove links to topics not available in the portal, and requires pipelineParameters "portal" (), "contextKey" (), and "removeFilteredEntries", a boolean controlling whether to remove or simply mark links to filtered content. false String None
projectKey The Project key. Overridden by url and/or urlString. false String none
recordPageview Whether to record a pageview for the given content in the reporting system. This should only be true when viewing content in a custom portal page. The built-in content viewing pages all record the pageview before the response is rendered. But when rendering content on a custom portal page, this should be specified as true to ensure that the content view is recorded. false boolean false
searchTerm A search term whose first result will be the rendered by this tag. Overrides url and contextUrl attributes. Required if url attribute not provided. Can be combined with metadata specified in metadataFilterTags. false String none
timeout The amount of time, in ms, after which the transform may be cancelled. The default value is generally 60000 (60 seconds), though this can vary depending on the application's configuration. Set to 0 to disable timeouts, but do this with care; infinitely-running transforms can severely degrade application performance site-wide. false long 60000
url The object describing the content to retrieve. Required if searchTerm attribute is not provided. false none
urlString The object describing the content to retrieve. Required if searchTerm attribute is not provided. false String none
xsl Relative path to an XSLT file, relative to the WEB-INF directory of the web application, to apply to the content. Parameters to the XSLT can be passed using nested xslParam tags. false String none