SIMPLEMODAL is a small plugin used to create modal windows. It is used to generate alert or confirm messages with few lines of code. Confirm configuration involves the use of callbacks to be applied to affirmative action. It can work in asynchronous mode and retrieve content from external pages. It can also get the inline content.
SIMPLEMODALis not a lightbox although the possibility to hide parts of its layout may partially make it similar.
SIMPLEMODAL is very easy to use there are 4 ways to create SIMPLEMODAL:
1. Simple alert message
2. Modal window
3. Modal window with a single asynchronous call
4. Lightbox
Alert Integration
1 2 3 4 5 6 7 |
$("myElement").addEvent("click", function(){ var SM = new SimpleModal({"btn_ok":"Alert button"}); SM.show({ "title":"Title", "contents":"Your message..." }); }); |
Modal Integration
1 2 3 4 5 6 7 8 9 10 11 12 13 |
$("myElement").addEvent("click", function(){ var SM = new SimpleModal({"btn_ok":"Confirm button"}); SM.addButton("Action button", "btn primary", function(){ alert("Add your code"); this.hide(); }); SM.addButton("Cancel", "btn"); SM.show({ "model":"modal", "title":"Title", "contents":"Your message..." }); }); |
Requirement :- jQuery library
Download :- http://mydons.com/download/75b5411e5c83ea7e9a8f9f80d0746f21/plasm-simplemodal-1.1-0-gbdf609d.zip
License :- MIT license