Hi everyone. I am building a website that performs some requests to another server, retrieves the information and then displays it. The requests are made with XML files that are dynamically created from my page. My website works like this:
There is one page with a form where the user must enter the search criteria. Then the form posts the user entered data to another webpage.
The second webpage puts them into an XML, posts it using cURL and stores the response into a string variable. The variable then is parsed with PHP’s simple XML and echoes them.
The problem is that went the second page loads, the status bar say that the page is loaded while the page seems blank. After a while the page starts to load again and the displays the retrieved data. I tried to find out why this happens and I erased everything except from the XML that is posted and the cURL code that posts it and assigns the response to a variable, so I came up with the conclusion that cURL is responsible. The XML that I send is about 15 to 20 lines long and it’s well formatted so I don’t think the XML is the problem, but the response XML might be huge depending on the search data entered.
Can anyone tell me how to fix this problem or how to display a “Loading…” or something while the page seems blank? I’m sorry for the huge post. Thanks in advance!