PDA

View Full Version : Ajax Tabs and JavaScript



btr1976
06-14-2006, 07:30 PM
http://www.dynamicdrive.com/dynamicindex17/ajaxtabscontent/index.htm

I am trying to use the Tabs just like Yahoo. In each of the tabbed pages, I need JavaScript (because I am using RSS feeds to display other headlines under those tabs). I understand that the Javascript needs to be saved as a separate .js file and the "rev=whatever.js" attribute needs to be used. However it doesn't seem to be working for me. When I save my JavaScript as content.js and then use the code:
<li><a href="content.htm" rel="contentarea" rev="content.js">Content</a></li> ,

I get a js error when I try to view my page.

Does anybody know the steps (or if it already exists, please point me to the page) that shows how exactly to do this?

Thanks.

ddadmin
06-15-2006, 06:56 AM
What's the JavaScript you're trying to load? The load .js feature is simply offered as a convinience, and won't work well in complex JavaScript cases.

An easier way perhaps is just to use an iframe based content loader instead, such as: http://www.dynamicdrive.com/dynamicindex3/tabdocviewer.htm