Page 1 of 1

ResponseXML size limit

Posted: Wed Oct 21, 2009 10:25 pm
by jeffmatthews
Don't know if this is a client or server side issue, but responseXML is not retrieved/sent if it is large. In my case, it dies when trying to send an xml of about 2.5 megs back to client.

Is there some setting for this?

Thanks.

Re: ResponseXML size limit

Posted: Wed Oct 21, 2009 11:15 pm
by John Cartwright
Are you getting any errors? You can try increasing php's memory limit and it's timeout.

ini_set('memory_limit', '64mb'); + set_time_limit(120); //2 minutes

Re: ResponseXML size limit

Posted: Thu Oct 22, 2009 9:24 am
by jeffmatthews
Thanks. I already had the timeout set higher. I'll set the memory limit and post back.

Re: ResponseXML size limit

Posted: Thu Oct 22, 2009 9:40 am
by jeffmatthews
No. That didn't work.

Also, I forgot to add, this php file is called from javascript. If I go to my browser's address bar and call it directly (supllying the parameter), it echos back everything.

So, the more I think about it, logic tells me this error is on the clinet side in javascript.

Re: ResponseXML size limit

Posted: Thu Oct 22, 2009 1:51 pm
by Christopher
Moved to the Javascript forum as it may be a client side issue.

Re: ResponseXML size limit

Posted: Thu Oct 22, 2009 4:56 pm
by jeffmatthews
Incidentally, I modified the code to only allow for pulling the first 4 of 150+ polygons. It still works, so there is nothing wring with the polygon coding. This clearly has to be a problem with the size of the ResponseXML.

Nobody has encountered this before? :?: :?: :?:

Re: ResponseXML size limit

Posted: Thu Oct 22, 2009 9:59 pm
by jeffmatthews
Well, it turns out is not a size issue (as far as I can tell).

It was finding "junk after document element," but for the life of me, there was none (or if there was, it was invisible). I changed the file load type as follows from simplexml to just plain-old contents, and it's okay. Sorry for any inconvenience.

//$polyxml = simplexml_load_file($cPolyXMLFile);
$polyxml = file_get_contents($cPolyXMLFile);
echo ($polyxml);
return;