Configuring a custom Footprint radiobutton field
Users can pick an option from a Footprint radiobutton field.
Procedure
- Access your Content Manager server and navigate to %TRIDION_HOME%.
- Navigate to the subfolder web\WebUI\Models\SiteEdit\Configuration\.
- As a precaution, back up the file SiteEditModel.config.
- Open the file SiteEditModel.config in a plain-text or XML editor.
- Find the
customconfigurationsection. This section has a subsection calledclientconfiguration, which in turn contains afootprintssubsection.You see the list offootprintelements that represent the Footprints which are currently displayed in the Footprint Set dialogs. - Insert a new
footprintelement for the custom Footprint field you want to configure, and give it the following attributes:ID- a unique string that identifies this Footprint
ClaimUri-
the URI of a Claim associated with this Footprint, for example:
taf:claim:foo
- Insert a
<title>section inside your newfootprintelement. - For each language that your installation of SDL Web supports, insert a
valueelement inside thetitleelement, and give it alangattribute set to the four-digit Microsoft locale ID belonging to that language:1031for German1033for US English1036for French1041for Japanese1043for Dutch3082for Spanish
- Set the contents of each
valueelement to the localized name of this Footprint, as you want it to appear in the Footprint Settings dialog. - Also insert a
valueelement without alangattribute. This is used as a fallback if the language is none of the above. (If you do not insert such avalueelement, the value of theIDattribute of the parentfootprintelement is displayed.)You have now configured a title for your Footprint. - If you want, you can also write a description for your Footprint. The description appears under the title in the content area on the right if the user selects this Footprint. To create a Footprint description, insert a
<description>section inside your newfootprintelement, directly under the<title>section. - For each language that your installation of SDL Web supports, insert a
valueelement inside thedescriptionelement, and give it alangattribute set to the four-digit Microsoft locale ID belonging to that language. - Set the contents of each
valueelement to the localized description of this Footprint, as you want it to appear in the Footprint Settings dialog. - Also insert a
valueelement without alangattribute. This is used as a fallback if the language is none of the above. (If you do not insert such avalueelement, an empty string is displayed.)You have now configured a description for your Footprint. - Specify a default value for this Footprint.
To specify a default value, insert a
<values>section inside thefootprintelement. Inside<values>, create avalueelement with the following attributes:text-
The value of the field, as it will be submitted. Set this attribute to the empty string (
text="") to make the empty value default. default-
Set this attribute to
true.
- For each language that your installation of SDL Web supports, insert a
labelelement inside thevalueelement, and give it alangattribute set to the four-digit Microsoft locale ID belonging to that language. - Set the contents of the
labelelement to the localized text that you want to use to represent the value. For example, if the value refers to the African continent, and thelabelhas alangattribute set to "1036" (France), then the contents oflabelwould beAfrique. - Add a
valueelement for each of the allowed values, specifying atextattribute and a set oflabelsubelements, as you did for the default value. (For these new elements, omit thedefaultattribute.) - Also insert a
labelelement without alangattribute. This is used as a fallback if the language is none of the above. (If you do not insert such alabelelement, the value of thetextattribute of the parentvalueelement is displayed.)You have now configured a default value for your control. - If you want, repeat steps 5-18 to configure further custom Footprint fields that use a radiobutton control.
- Save and close SiteEditModel.config.
- Navigate to the subfolder web\WebUI\Editors\SiteEdit\Configuration\.
- As a precaution, back up the file SiteEditEditor.config.
- Open SiteEditEditor.config.
- Find the
customconfigurationsection. This section has a subsection calledclientconfiguration, which in turn contains afootprintssubsection.You see the list offootprintelements that represent the Footprints which are currently displayed in the Footprint Set dialogs. - Create an icon for the custom Footprint in the form of a set of PNG files named footprint.<iconname>.16x16.png (16 by 16 pixels), footprint.<iconname>.24x24.png (24 by 24 pixels), footprint.<iconname>.32x32.png (32 by 32 pixels) and footprint.<iconname>.48x48.png (48 by 48 pixes), where <iconname> is a name for your icon. Save these files in the folder %TRIDION_HOME%\web\WebUI\Editors\SiteEdit\Themes\Carbon\Images\Icons\.
- Add a new
footprintelement with the following attributes:ID- The identifier of the Footprint, as set in SiteEditModel.config.
ControlID-
Set this to
FootprintRadio. Icons- The name you provided for the icon (<iconname>).
- Repeat this step for each new Footprint you configured in SiteEditModel.config.
- Save and close SiteEditEditor.config.
- In the cd_ambient_conf.xml Ambient Data Framework configuration file, add a new
Claimelement in theGloballyAcceptedClaimssection and set itsUriattribute to the Claim URI of your new Claim.