All,
I am using JQuery UI Nested tabs. Consider the structure like this: There are 2 Main tabs: Animals, Birds. Under Animals, there are two tabs "Cats", "Dogs". Both the tabs "Cats" and "Dogs" should be loaded via AJAX when selected.. So, the code for them is something like this:
<div id="fragment-1">
<ul>
<li><a href="/public/catstab" title="Cats"><span>Cats</span></a></li>
<li><a href="/public/dogstab" title="Dogs"><span>Dogs</span></a></li>
</ul>
</div>
<script type="text/javascript">
$(document).ready(function()
{
$("#tabs-loading-message").show();
$('#fragment-1').tabs({cache:false, spinner:''});
});
</script>
The issue is, I want to maintain a common div to load the AJAX urls. Ex: When you click on Cats or Dogs, the content for those tabs, should go into "<div id='commonDiv'></div>
instead of going into "cats"
div and "dogs"
div.
The loading should be reusable, in the sense, if call reload("Dogs")
from anywhere inside "dogs"
tab, it should reload the "dogs"
tab content.
How can I achieve this?