Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/kairichard/jquery.confirm.js
jQuery Plugin which adds confirmation to an Event on the DOM
https://github.com/kairichard/jquery.confirm.js
Last synced: 9 days ago
JSON representation
jQuery Plugin which adds confirmation to an Event on the DOM
- Host: GitHub
- URL: https://github.com/kairichard/jquery.confirm.js
- Owner: kairichard
- Created: 2010-05-07T08:43:00.000Z (almost 15 years ago)
- Default Branch: master
- Last Pushed: 2014-02-15T09:55:50.000Z (almost 11 years ago)
- Last Synced: 2023-04-12T15:06:42.717Z (almost 2 years ago)
- Language: JavaScript
- Homepage: kairichardkoenig.com
- Size: 129 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
jQuery.confirm lets you add a confirmation-layer to any element on any event.
Depends on:
http://github.com/brandonaaron/livequery
--------
Usage:jQuery('a.delete').confirm({});
Now if you click the "a.delete" Link it will replace the parent with the confirmation markup.
If you the decide to confirm your deletetion it will fire the callback.
When you cancel the confirmation it will replace the confirmation markup with the previous parent's content.Options:
```
confirm_class:"blueButton",
abort_class:"greyButton",
confirm_text:"Löschen",
abort_text:"Abbrechen",
event:"click"
callbacks:{
clicked_confirmation:function(event){
event.preventDefault();
jQuery.ajax({
url:event.data.href,
dataType:"script"
});
}
}
```
--------
Than it looks like this![Alt text](http://pickhost.eu/images/0003/4559/Picture_3.png)
If you click on the "X"
![Alt text](http://pickhost.eu/images/0003/4560/Picture_4.png)