HTMLDocType and HTMLOptions custom properties
The HTMLDocType and HTMLOptions custom document properties can be specified in UNICOM Intelligence Professional or via the Custom Properties tab in UNICOM Intelligence Author. If the custom properties are not specified in the MDM document, each application will use a default HTML DocType.
The IOM.CustomPropertiesContext setting is typically used to control whether the MDM custom properties (MDM.Properties), in special context, are output to the Player XML. Only the HTMLPlayer uses the HTMLDocType and HTMLOptions custom properties.
The mrScriptMeta definition is as follows:
Metadata(en-GB, Question, Label)
HDATA -
[
Template = "DefaultLayout.htm",
HtmlDoctype = "<!DOCTYPE HTML>",
HtmlOptions = "NoExpiryMetaTags,NoAutoJump"
];
Gender "What is your gender?" [MyCustomProp = 42]
categorical [1..1]
{
Male "Male",
Female "Female",
"Other" "Other"
};
End Metadata
In order to show the custom properties at the question level, the routing script is as follows:
Routing(Web)
IOM.CustomPropertiesContext = "Question"
Gender.Ask()
End Routing
The properties XML representation is as follows:
<Page SavePoint="Gender" Project="TESTPROJ" Language="en-GB" Context="Question" LabelType="Label" RoutingContext="DefaultRouting" SessionToken="hytv6y3gwipe4pvga63zibo55yaqaaaa" EstimatedPages="10" EstimatedProgress="2" Renderer="HTMLPlayer">
<Properties>
<Property name="HtmlDoctype" Value="<!DOCTYPE HTML>"Type="8"/>
<Property name="HtmlOptions" Value="NoExpiryMetaTags,NoAutoJump" Type="8">
</Properties>
<Title>
<Style ElementAlign="Right"/>
<Text>Gender</Text>
</Title>
<Question QuestionName="Gender" QuestionFullName="Gender" QuestionDataType="Text">
<Properties>
<Property name="MyCustomProp" Value="42" Type="3">
</Properties>
</Page>
See also