0
I have three tabs with bootstrap, the option to navigate the tabs with the buttons back and next are working, as picture below:
How do I enable the next tab only if all fields of the first tab are filled in the same way in the second tab and leave the last two tabs as disabled by default when the first tab is active?
can traverse all inputs with jquery, $('.input-client'). each();
– Marcelo Bonus
You can disable the button
Próximo
, and only enable when all fields are filled in. Hence you link this button on the other tab, and so on... And on the tab link (Preferências do cliente
for example) you put "#" in thehref
, which is not to go to tab clicking there. You can do it with jQuery or pure Javascript... put the code there that you should get the answer you’re looking for quickly. In time: tbm is only possible to enable the tab link when fields are filled in.– gustavox
The most complicated I think is if you want to validate all fields, because each one will have the specific rules, but if for example you just want to know if there has been modification in all fields, you can use the function
change
orone
to check if all fields have been changed...– gustavox