CMS help pages
  
You are here: Home > Developers > How to build templates > SectionID

SectionID

type=sectionID

This returns the unique ID of a section within the usercontent. This is helpful when referencing sections from scripts. It allows section templates to identify an element within an individual section without using the document tree.

Example:

<div id="<cms type=sectionid>">Some text</div>
<input type="button" value="Change text" onclick='document.getElementById("
<cms type=sectionid>").innerHTML="Some other content"'>