getHtml(id).settings.checkboxWarning( message )

Defines the error message that gets displayed if an obligatory checkbox is not checked when calling warn. If you use %name% in the string it will be replaced with the element’s name.


[js highlight=”2″ try=”true”]newHtml(“intro”, “example_intro.html”)
.settings.checkboxWarning(“It is highly recommended that you check the ‘%name%’ box before continuing”)
.settings.radioWarning(“Please consider selecting an option for ‘%name%'”)
.settings.inputWarning(“We would like you to type some text in these fields”)
newButton(“I have completed the form”)

Will print the custom warning messages on any missing obligatory field after clicking “I have completed the form.”

Published by Jeremy

Researcher in semantics and pragmatics; Programmer of PennController for IBEX