Drawing multiple AJAX requests during body onLoad
0 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Steve_A
Posted On:   Wednesday, August 16, 2006 04:23 PM

Good day. I have a page that I am developing that has multiple select lists. I have developed code that allows the user to click the associated label for a particular select list and the list will reload from the database. These labels all use a generalized routine to call for the data. IE:"getSelectInformation('Data.php?TableName=TESTS&FieldName=TestName','TestCell','Test','-All')" will query the table Tests for the field TestName and place the select Options list in the Test SELECT form. [The "TestCell" is part of a workaround for the .innerHTML problem of the SELECT form. THe '-ALL-' is an addition to the OPTIONS list to allow the user to "unselect" and allow all options in that list to be ignored as part of the   More>>

Good day.



I have a page that I am developing that has multiple select lists. I have developed code that allows the user to click the associated label for a particular select list and the list will reload from the database. These labels all use a generalized routine to call for the data. IE:"getSelectInformation('Data.php?TableName=TESTS&FieldName=TestName','TestCell','Test','-All')" will query the table Tests for the field TestName and place the select Options list in the Test SELECT form. [The "TestCell" is part of a workaround for the .innerHTML problem of the SELECT form. THe '-ALL-' is an addition to the OPTIONS list to allow the user to "unselect" and allow all options in that list to be ignored as part of the query]



Currently, the lists are all "hard coded" during the page load and I am testing how to use these same AJAX calls to load the select forms. (I am aware that I can use these as a PHP page instead and load the select dynamically as the page loads, I am just using this as an example of the problem I am having)



What's the problem:

If I have a
and have two of the getSelectInformation calls within it. Only the second getSelectInformation call works. If I have the first one call to load the Materials Select list and the second to load the Test list, then only the Test list loads. If it is the inverse order, then only the Materials list would load.



Any ideas on what is happening?

If it is because they are both calling the same php page, is there a fix or anything I can do to work around it?

   <<Less
About | Sitemap | Contact