A simple Jquery UI toggle button
Full documentation & demos can be found at: http://eventengineering.github.io/supertoggle
Features
SuperToggle Includes a number of useful features:
- Custom On/Off Values
- Custom On/Off HTML
- Defined set of CSS classes for object customisation
- Default Value
Setup
Setting up SuperToggle could not be simpler.
Include the css and the library
<script type="text/javascript" src="supertoggle.js"></script>
Create an button element to be the SuperToggle.
<button id="example-toggle"></button>
Turn the element into a SuperToggle with some simple javascript
$("#example-toggle").supertoggle();