Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8429985
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T05:29:08+00:00 2026-06-10T05:29:08+00:00

When testing my application on ubuntu and the chromium browser everything works OK, but

  • 0

When testing my application on ubuntu and the chromium browser everything works OK, but when moving to the production machine which uses debian and the same chromium browser, I always get an ajax error 0.

  • jQuery version 1.7.2
  • jQuery.mobile version 1.1.1
  • Tomcat server

Request:

$.ajax({
    type: 'POST',
    url: "http://localhost:8080/rest/setvalue/1234",
    dataType: "json",
    success: function(objResponse) {
        showMessage("Done");
    },
    error: errorHandler
});

The errorHandler gets called on the production machine, although the server processes the request correctly!

Thanks for any ideas…

Frank

—— ADDED ——

Alert shown with the code

function errorHandler(xhr, ajaxOptions, thrownError) {
showAlert("Error", "Error: " + xhr.status + "\n" +
       "Message: " + xhr.statusText + "\n" +
       "Response: " + xhr.responseText + "\n" + thrownError); } 

is:

Error: 0

Message: error

Response:

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T05:29:09+00:00Added an answer on June 10, 2026 at 5:29 am

    A parenthesis is missing in the success function.

    showMessage(“Done”; should be showMessage(“Done”);

    Could you check if this solves the problem?

    EDITED:

    My opinion is that the problem is not code related. Most probably the AJAX request in your case is considered as a cross domain request and the same origin policy fails. That’s why you get Error:0.

    I managed to reproduce the case (in Windows OS) and I’m getting the same error in the following cases:

    1. Open my Web Page http://localhost:7001/MobileApp/index.html and perform AJAX on http://www.example.com/MobileApp/test.
    2. Open my Web Page http://localhost:7001/MobileApp/index.html and perform AJAX on http://127.0.0.1:7001/MobileApp/test.
    3. Open my Web Page http://127.0.0.1:7001/MobileApp/index.html and perform AJAX on http://localhost:7001/MobileApp/test
    4. Open my Web Page http://192.168.1.2:7001/MobileApp/index.html (where 192.168.1.2 is my private IP address) and perform AJAX on http://127.0.0.1:7001/MobileApp/test.

    The above cases were considered as cross domain requests and I got the the error you are mentioning.

    Obviously after configuring my hosts file and mapping IP addresses to host names etc some of the above issues were resolved because the requests were not considered as cross domain.

    In conclusion I would suggest to investigate whether the same origin policy succeeds.

    enter image description here

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

What would be the ultimate web application browser compatibility test machine be? The testing
I have written a psychological testing application, in which the user is presented with
On testing my application in Simulator, my app runs perfectly. But on the real
I have a remote Ubuntu Linux for testing a Ruby on Rails application. I
My little SQLite testing application is working, and everything is 100% functioning as expected.
I'm developing a BlackBerry app which uses an embedded browser to display html content.
Currently I'm using TestNG framework for testing application business logic, i added some Servlet
Is there any way to update my beta testing application on windows phone marketplace?
I am testing an application using Selenium IDE. There is a table with unstable
I am unit testing an application on the iPhone, and I'm trying to develop

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.