Hi,
I use tabs, loading content by ajax, and I'm very happy with that, but I'm a litle problem:
When I click on a tab, on first load, any access to objects like:
- $("#my_input_text").val('my value')
works fine, but if a click on another tab, and click again to the previous tab, the same code don't update the input text.
I think that is because the document has 2 inputs with the same id after second refresh. To prove this, I did, on javascript console of firebug:
- document.getElementById('my_input_text').id = "bad_my_input_text";
and
- $("#my_input_text").val('my value')
works again...
Exist some way, when click on a new tab, before load a content, clean all data from previous tab?
Thanks,