Forum Moderators: open

Message Too Old, No Replies

AJAX newbie needs help running two scripts on the same PHP file

         

Tekkno

10:57 pm on Oct 2, 2009 (gmt 0)

10+ Year Member



I have two AJAX scripts that I am trying to simultaneously and I need help. The first one calls a PHP file which has 20 sets of UL's in it, based on the tab the user chooses the specified UL loads into a div dynamically.
The second script points to the same PHP file, and is supposed to create a tree view of any menu that has a sub-menu associated with it.
The first script works flawlessly. But with the second script, I cannot get it to work with the same content (works in a test HTML file I created). I have a very limited knowledge of AJAX and may just need some tips. I have used Firebug (another program I am not familiar with) and I can see the code for both scripts loading, and I am guessing they are not synching. Here are the AJAX scripts.

<snipped code dump>

[edited by: whoisgregg at 2:16 pm (utc) on Oct. 5, 2009]
[edit reason] Whoops, no code dumps. Please see Sticky :) [/edit]

whoisgregg

2:20 pm on Oct 5, 2009 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Welcome to WebmasterWorld, Tekkno!

Often times folks who have trouble with AJAX scripts are using AJAX sample code from random sources that can be pretty out-of-date. Have you tried using one of the popular javascript libraries for your AJAX needs? Any of these have up-to-date functions that tend to make AJAX a lot simpler to deal with: Prototype, jQuery, mooTools, or YUI Library.