PDA

View Full Version : [SOLVED] AJAX tabs - all inline, not external files?



mikeberg62
07-17-2007, 10:56 PM
1) Script Title: Ajax Tabs Content script

2) Script URL (on DD): http://www.dynamicdrive.com/dynamicindex17/ajaxtabscontent/

3) Describe problem: I am using the AJAX tabs on a Joomla website. I want to load a Joomla module in each tab. This is a php call, like this:

<?php mosLoadModules( 'newsfeed2' );?>

Unfortunately, that doesn't seem to work. The "default" tab works fine, since the php call is loaded when the page loads. I think that maybe it's not working because loading a new tab does not re-parse the php call that exists in the external file...? My experience with php is limited, so correct me if I'm speaking gibberish.

The question I have is this: Is it possible to have the contents of each tab exist right on my html page, rather than have them loaded from an external html file?

I hope this makes sense...

ddadmin
07-18-2007, 07:51 AM
The question I have is this: Is it possible to have the contents of each tab exist right on my html page, rather than have them loaded from an external html file?

If I understood you correctly, certainly. That's what the original version of this script, Tab Content script (http://www.dynamicdrive.com/dynamicindex17/tabcontent.htm), does.

mikeberg62
07-18-2007, 01:46 PM
That's exactly what I needed. See it in action here:
(site is still a work-in-progress)
www.foreignaid.ca (http://www.foreignaid.ca/)

tane
07-26-2007, 01:37 PM
putting other joomla modules within ajax tabs is exactly what I want to do as well.

I've checked out the other link for the tab content script but still don't understand where or how to insert the html code for the tabs within joomla, do I put it in the template html code, within the module alax tabs module somehow or other place?

help much appreciated!

mikeberg62
07-26-2007, 11:13 PM
Yes, I added the html for the tabs into my template, with some php code that tells it to only show up on the homepage.

If you are looking for tabs inside a content item, that's a different story. I recommend checking out "Tabs and Slides in Content Items" from JoomlaWorks: http://www.joomlaworks.gr/#downloads_section