Skip to content

JQuery plugin that makes users click a button twice to submit a form

License

Notifications You must be signed in to change notification settings

baturkey/buttonguard

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Buttonguard

Buttonguard is a JQuery plugin that makes users click a button twice to submit a form

Example

Requires

Options

Option Default Value Description
newHtml Confirm What the button will display after being clicked
oldClass The CSS class to change from. newClass also needs to be set
newClass The CSS class to change to. oldClass also needs to be set
duration The length of time in ms that the button will be active after the first click. If not set the button will stay active

Usage example

<button class="btn btn-primary" id="AButton">Click</button>
$(function() {
	$("#AButton").buttonguard({
		duration: 5000,
		oldClass: 'btn-primary',
		newClass: 'btn-danger'
	});
});

About

JQuery plugin that makes users click a button twice to submit a form

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages