PDA

View Full Version : How would I summon the page and display specific content in container div using Ajax?



simcomedia
10-12-2009, 10:01 PM
1) Script Title: Dynamic Ajax Content

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

3) Describe problem:

I want to be able to load an .html page with specific content in the container div. The Ajax Tabs script does it where you specify in the url what menu item or 'tab' content you wish to display upon page load by doing something like www.sitename.com/page.html?ajaxtabs=3 which then loads the 3rd item in the <ul class="ajaxtabs"> list of links.

I have a page that has a similar list using the dynamic ajax script (not the tabs script) that I want to accomplish the same thing. That way I can have other hyperlinks to the page that on arrival would have the specific content in the container <div>.

To further clarify, I have a menu (horizontal) utilizing a <ul> type setup with 6 hyperlinks. Each of the links summons content into a container <div> to the right of the menu. This works brilliantly.

What I want is to have a link TO that page to display the page AND one of the specific pages listed in the <ul> menu in the container <div> upon arrival. So, if I create a hyperlink to that page and want the 3rd item in that link to be displayed upon arrival.... how would I accomplish that?

In looking at the Ajax Tabs .js file it appears there's a function written to hold those tab/links in an array that could be later summoned. I'm not a JS guy so looking for some help on this.

Thanks!