Toggle fieldsets visibility, but also save hidden data.

My form has a selector with many 'providers'. When selecting a provider, inputs relating to that particular provider are shown. Problem is that I want user to be able to switch between providers, without losing settings for other providers.

What is the most straight-forward way to accomplish this? Simply showing/hiding fieldset doesn't work, because data for hidden fields is not saved.
Was this page helpful?