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 9311903
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 19, 20262026-06-19T01:29:40+00:00 2026-06-19T01:29:40+00:00

This is more a question of procedure than anything else. I’m curious why this

  • 0

This is more a question of procedure than anything else. I’m curious why this happens and I can’t seem to find any documentation on this “feature” within the ECMA script documentation.

When I make an AJAX call within jQuery to my server, it returns the following JSON response to the page:

{"version":"v1","status":"OK","timestamp":"2013-02-14 10:32:45","data":"true","error":""}

With this string I have to call jQuery.parseJSON(string); to get it as an object, and the be able to reference it as an object.

However, when my server returns something like this:

{"version":"v1","status":"OK","timestamp":"2013-02-14 10:12:19","data":{"a":"asgsadfga","b":false,"c":[]},"error":""}

Javascript automatically loads this an an object without the need to parse. It would seem that because this example returns a nested object, despite the fact it was returned from the server as a string, Javascript will immediately recognize that, and parse the string for me.

Is this expected functionality, and if so, can anyone point me to the documentation of this?

EDITED:

Here is the offending AJAX call:

    jQuery.ajax({
        url: url,
        type: 'GET',
        async: false,
        success: function (result) {
            console.log(result)
        }
  • 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-19T01:29:41+00:00Added an answer on June 19, 2026 at 1:29 am

    According to ajax() in jQuery API Documentation under dataType:

    dataType (default: Intelligent Guess (xml, json, script, or
    html))Type: String The type of data that you’re expecting back from
    the server. If none is specified, jQuery will try to infer it based
    on the MIME type of the response (an XML MIME type will yield XML, in
    1.4 JSON will yield a JavaScript object
    , in 1.4 script will execute the script, and anything else will be returned as a string).

    Hope this helps.

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

Sidebar

Related Questions

This is a followup question to PHP: if more than ..px resize to As
This is probably more of a best practices question than a true code question.
This is more of a general best practice question rather than a very focused
This is more a question of pros/cons between PHP and JAVA. Iv been doing
This is more a question of practical database design. I've designed smaller databases before,
ASP.Net MVC3 is cool and all but I have this question more out of
I'm not talking about making portable code. This is more a question of distribution.
This is more of a question about getting my head around the process I
This is more of a question of syntactic elegance, but I'm learning C++ and
This is more a general question but my particular case involves a ruby/rails app

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.