Plugins

User login
Can't find a Plugin?

Can't find a Plugin you are looking for? Check out the jQuery Wiki page.

Are you a plugin developer? Please move your plugin over to this site.

Website Bug or Feature Request?

Found a bug on the new jQuery Plugin website? Have a feature request?

Submit it to the jQuery Plugin website issue queue to ensure it is noticed!

jqDialog


Average rating
(4 votes)

jqDialog is a small (3.7 KB minified) dialog plugin that provides smooth, persistent, non-intrusive alternatives for alert(), confirm() and prompt(). There is also a notify() dialog that pops up and goes away in X seconds.

Dependencies

jquery (1.3)

Demo

http://kailashnadh.name/code/jqdialog

How to use?

notify dialog

jqDialog.notify("This dialog will disappear in 3 seconds", 3);

/* __________________ */
jqDialog.notify("This dialog will stay");
jqDialog.close(); // this makes the dialog go away

alert dialog

jqDialog.alert("This is a non intrusive alert",
    function() { // callback function for 'OK' button
        alert("This intrusive alert says you clicked OK");
    }
);

confirm dialog

jqDialog.confirm("Are you sure want to click either of these buttons?",
    function() { alert("This intrusive alert says you clicked YES"); }, // callback function for 'YES' button
    function() { alert("This intrusive alert says you clicked NO"); } // callback function for 'NO' button
);

prompt dialog

jqDialog.prompt("Please enter your name",
    'Sam',
    function(data) { alert("Your name is " + data); }, // callback function for 'OK' button
    function() { alert("This intrusive alert says you clicked Cancel"); } // callback function for 'Cancel' button
);

custom content dialog

jqDialog.content('No dialog controls, just custom content<br /><input type="text" name="test" />');

Releases

Official releasesDateSizeLinksStatus
1.2.12009-Sep-0523.82 KBRecommended for 1.0.xThis is currently the recommended release for 1.0.x.
1.22009-Sep-0223.68 KBRecommended for 1.3.xThis is currently the recommended release for 1.3.x.