aspose file tools*
The moose likes HTML, CSS and JavaScript and the fly likes not send XMLHttpRequest request in mobile web Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "not send XMLHttpRequest request in mobile web" Watch "not send XMLHttpRequest request in mobile web" New topic
Author

not send XMLHttpRequest request in mobile web

Garden Pak
Greenhorn

Joined: Apr 23, 2013
Posts: 4
I made a web page to send http request to WAS.
The page sends request well in PC but in mobile(Android) cannot send the request.

Here's the code.

In PC alerts readyState like "1" -> "1" -> "2" -> "4" -> "3"
but in mobile "1" -> "4".
So it doesn't even send the request in moblie browser.
I tested in android default browser and Chrome - same result.
One strange thing is that it sends the request well in mobile when I type the request URL to browser without javascript.

Any ideas?

Thanks.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61773
    
  67

A ready state of 4 means complete, so I'm not convinced that the request isn't being sent. Have you monitored the server to see if it is so?

And why on earth aren't you using jQuery where all that code can be done with one line?


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Garden Pak
Greenhorn

Joined: Apr 23, 2013
Posts: 4
But there's no responseText and httpRequest.status is 0.
hm.. I'll try JQuery.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: not send XMLHttpRequest request in mobile web