Getting Started | API | Elements | Actions | Validators | Handlers | Configuration Options | Advanced Guides | Troubleshooting | About
This element produces a toggle switch formatted by jQuery Mobile.
#mobile_toggle {
id=room_lights,
theme=c,
on_text="Lights On",
on_value="on",
off_text="Lights Off",
off_value="off,
selected="off",
postback=switch_lights
}
on_text
(string) - The text label of the 'on' position (default "On")
off_text
(string) - The text label of the 'off' position (default "Off")
on_value
(string) - The value that is submitted with postbacks when in the 'on' position (default "on")
off_value
(string) - The value that is submitted with postbacks when in the 'off' position (default "off")
selected
(string) - The default selected value (default "off")
postback
(term) - If specified, will postback immediately on hitting the toggle