VinceG / twitter-bootstrap-wizard

This twitter bootstrap plugin builds a wizard out of a formatter tabbable structure. It allows to build a wizard functionality using buttons to go through the different wizard steps and using events allows to hook into each step individually.
MIT License
1.39k stars 676 forks source link

Reset Wizard? #106

Closed jeffhoang closed 8 years ago

jeffhoang commented 9 years ago

How do I reset the wizard upon submission?

shamanis commented 9 years ago

I join issue. I have to call location.reload() in onFinish. Lost all async. Trigger 'click' for 'a[href=tab]' does not make sense because onTabClick disable in my case.

UPD: I found a way out. Call $('#Wizard a[href="#tab1"]').tab('show') in onFinish. Just before it resets all form.

kheide commented 9 years ago

Cant get your solution to work either @shamanis !

Has anyone else figured out something? Author?

jeffhoang commented 9 years ago

I'm using reactjs with this. My work around was to store the original dom and its children in an instance variable. Upon submission or cancellation, I just restore (replace) the modified selector with the original dom.

I just feel the design of this framework is flawed...example, I don't like how section is replaced with div's, etc...

VinceG commented 8 years ago

@jeffhoang @kheide @shamanis there is a method called resetWizard