View Single Post
Old 04-02-2010, 05:09 PM   PM User | #1
enigma12814
New to the CF scene

 
Join Date: Dec 2007
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
enigma12814 is an unknown quantity at this point
Advice with XMLHTTPRequest

I have a complex issue I am having trouble resolving. Basically I am trying to create a live user queue with some combination of ajax and php. When someone enters the queue I insert their ID into the database. Now, here is my problem. Disclaimer: I'm not an expert programmer.

I have page 1 with a setinterval command that is running an xmlhttprequest to page 2. Page 2 (completely php) is basically just counting the rows in the database to see how many users are in the queue and reporting back a live update of how many users are there. I am trying to figure out how to do a redirect of Page 1 whenever Page 2 has found 5 users in the queue. Is there any way to pass a variable back to page 1 or something? Or do I need to code some javascript accessing the database instead of php?
enigma12814 is offline   Reply With Quote