Log in

View Full Version : jQuery alternative to DD Ajax Tabs



zorag
04-11-2009, 02:32 PM
Can anyone advise on an alternative jQuery method or maybe a plug in to the DD Ajax Tabs script, some of my designs don't use the tabs functionality of DD Ajax Tabs, I simply use the container to pull in pages with no tabs, Like this: http://www.myhooligans.com/index.php?t=home_index

I love the Ajax Tabs script but ultimately I would like to cross over to jQuery completely, any suggestions or offers of paid assistance would be appreciated.

Thanks

Medyman
04-13-2009, 01:14 PM
You don't need a plugin for that. You're just looking for regular AJAX functionality (without UI elements). Look into the .ajax() method of jQuery.

zorag
04-13-2009, 02:23 PM
Thanks Medyman

Would you be kind enough to show me an example please, for instance with Ajax Tabs I would use a call like this to pull in a target page into a DD Ajax container div from anywhere on the page:


<a href="javascript: containert.loadajaxpage('page.html')">

What would I use for the jQuery .ajax method if I had the container div named <div class="container"></div>

Medyman
04-13-2009, 07:18 PM
Using id="container" would probably be more ideal, but regardless, it works something like this:


$.ajax({
url: "page.html",
cache: false,
success: function(html){
$(".container").append(html);
}
});

Of course, this goes in <script> tags in the <head> of your document, not inline.

More information: http://docs.jquery.com/Ajax