The following jquery ajax call would return approx. 8442 characters in its “html” response. Content exceeding this number would be truncated.
var url = "load_pocket_fabrics.php?filter=" + $("#eleID").val(); $.ajax({ url: url, type: 'GET', dataType: 'html', timeout: 1000, async:false, before: $("#contentID").prev("div.loader").show(), success: function(msg){ alert(msg);return; } });
While searching for a solution/reason for this “abnormality” i ended up on a blog post subjecting a spelling error (“asynch” for “async”) which gave me an idea to use “async = false” in the above code and voila it worked! I can get an entire big page through jquery ajax now.
I hope this may help someone using jquery ajax for getting large data. Any idea or clarification of this topic is most welcome.