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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T08:54:37+00:00 2026-06-02T08:54:37+00:00

I am trying to parse a response from server and i am new to

  • 0

I am trying to parse a response from server and i am new to this topic, Unfortunately it is in JSONP format. I don’t know how to parse JSONP format, when i tried with JSON Parser it is returning null value.
Can anyone please help me in doing this…

Thanks in Advance.

  • 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-02T08:54:39+00:00Added an answer on June 2, 2026 at 8:54 am

    JSONP is just JSON wrapped in a JavaScript function call. For instance, something like:

    callback({"status":"success", "someVar":1});
    

    So you have a couple of options. If you are using a WebView you can define a function called callback in JavaScript and then just call eval() on the JSONP data. This will invoke the callback function, passing it the parsed JSON object (the eval() does the parsing for you).

    Or, if you have the JSONP string in your Java code, the simplest option is probably to extract out the JSON substring, like:

    String json = jsonp.substring(jsonp.indexOf("(") + 1, jsonp.lastIndexOf(")"));
    

    That will strip off callback( and );, leaving you with just {"status":"success", "someVar":1}, which should then parse with any standard JSON parser.

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

Sidebar

Related Questions

I am trying to parse a JSON response from a server using javascript/jquery. This
I am trying to parse a Json response from my webservice. I receive this
I'm trying to parse a JSON response with jQuery but it's not working. This
I was trying to parse response data from web server. I am using Xcode
I'm trying to parse the response from a web server. My parser does as
I'm trying to parse this XML string: <?xml version=1.0 encoding=UTF-8 standalone=no?> <response type=success> <lots>
I have validated the JSON response from my C# Webmethod, so I don't believe
I'm trying to use JSON, I'm getting the information from the server so I've
Trying to parse some XML but apparently this is too much for a lazy
when i try to parse the response returned from a web service i got

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.