Try something like this.  This is extracted from working code but it's
up to you to make it work for you.

In this example, I have two containers (tabs) with pay-as-you-go
loading.

There are surely other ways of doing this, or even generalizing this,
but it all depends on your particular circumstance.  Here I'm hard-
coding two containers for deferred loading.

$(function() {
   $("#MyTab1 a").click( function()  {
     getData('#container1');});

   $("#MyTab2 a").click( function()  {
     getData('#container2');});

   // Etc...
});

function getData (tcContainer)
{
  if (! $(tcContainer).data("isLoaded"))
  {
    // Fetch your container contents here
  }
  $(tcContainer).data("isLoaded", 1);
}


**--**  Steve


On Feb 16, 10:15 am, sw <[email protected]> wrote:
> hi
>
> i have a little trouble while using the tabs.
>
> you can view the test site her:http://test.divexit.de/
>
> the problem is the slow pageload so i would like to load the contents
> only on demand(klick)
> since a few days i am trying reading and so on but i don´t get
> forward.
>
> hopefully someone in here can help/point me to a solution
>
> thanks :-)
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"jQuery UI" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/jquery-ui?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to