Refactors confirm implementation to perform dom insertion seperately

The current implementation will not bind or unbind callbacks properly after your first use of the confirm dialog, which means your original callback is both a) stuck in memory and not dereferenced and b) your future callbacks don't actually get called.

I refactored the implementation to perform dom insertion separately, and also converted the binds to ons as per jQuery's 1.9 preferences.