Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by Nasir on May 14, 2009 06:31
open dhtmlx forum
load xml error on single quote

HI again,

You already closed the topic so please look at the following link for further information.

http://dhtmlx.com/docs/products/kb/index.php?s=normal&q=2508&a=15205

It seems if i load the data from xml file all seem to work fine, but when i use .php file to load the same data from the database i get the load xml error upon entering the single quote.

i'll post my php file that generated the xml file.

 

kind regards,

Nasir

Answer posted by Nasir on May 14, 2009 06:32
please find attached the php file.
Attachments (1)
Answer posted by Alex (support) on May 14, 2009 07:15

There is an white-space before <?xml declaration in your file. That can cause an issue in FF. 

Also you can try to use CDATA to set option text:

print("<![CDATA[".$CUSTOMER_NAME."]]>");

To check that your server-side script generates correct xml - just point your browser to it. If all is done correctly, the browser will show correct xml. 

Answer posted by Nasir on May 15, 2009 01:10
Even if use the CDATA i still get the loadxml error. any other suggestions?
Answer posted by Alex (support) on May 15, 2009 02:03

Please, check that encoding of the xml, database and page are the same. 

If the issue with xml loading still occurs, please provide a direct link to the problematic page (you can also send this information to support@dhtmlx.com)

Answer posted by Nasir on May 15, 2009 06:08

Hi,

I think there seems to be an issue with the whitespace in the first line as you mentioned. But any idea how to remove that whitespace would be nice?

  <?xml declaration

regards,

Nasir

Answer posted by Alex (support) on May 15, 2009 06:40

Hello, 

Just remove it in your server-side script that you provided before. There was a whitespase in the begging - before <?php ...