Try the following: http://jsfiddle.net/netwire88/NAbZT/16/
$(document).on("click", ".flipbox-forward", function(e) { e.preventDefault(); var $this = $(this); $this.flip({ direction: $this.data("direction"), color: $this.data("color"), content: $this.data("title"), onBefore: function() { $this.removeClass('flipbox-forward'); $this.addClass('flipbox-revert'); } }) }); $(document).on("click", ".flipbox-revert", function(e) { e.preventDefault(); var $this = $(this); $this.revertFlip(); $this.removeClass('flipbox-revert'); $this.addClass('flipbox-forward'); });
source share