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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T04:01:08+00:00 2026-05-26T04:01:08+00:00

Send JS object to JSP page I followed this link and found that one

  • 0

Send JS object to JSP page

I followed this link and found that one of the answer says that we can create a JSON object by using this constructor:

JSONObject jsonObj=new JSONObject(String_to_Be_Parsed);

But when I downloaded the library of JSON and put that jar in my project I found that it supports only two constructors namely:

JSONObject()
JSONObject(boolean) 

Although the documentation in the site of JSON also have a number of constructors including the one I want, JSONObject(String)?

What should I do?

  • 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-05-26T04:01:09+00:00Added an answer on May 26, 2026 at 4:01 am

    The link provided by the comment to that answer apparently was not the correct source (note that the comment had a different author than the answer). I have added a comment to correct it. The correct source is probably here: http://json.org/java/. (Actually it looks like there are numerous 3rd party implementations and this is just a reference implementation. It looks like it would work, except you have to build your own .jar apparently.)

    You can see the JSONObject(String) constructor right in the source for JSONObject.java.

    /**
     * Construct a JSONObject from a source JSON text string.
     * This is the most commonly used JSONObject constructor.
     * @param source    A string beginning
     *  with <code>{</code>&nbsp;<small>(left brace)</small> and ending
     *  with <code>}</code>&nbsp;<small>(right brace)</small>.
     * @exception JSONException If there is a syntax error in the source
     *  string or a duplicated key.
     */
    public JSONObject(String source) throws JSONException {
        this(new JSONTokener(source));
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm new to RubyAmf. I noticed that you can send an object with RubyAmf
Can i send object or bean instead of sending parameters in jsp request to
I have a JSP page that queries a MySQL database, I want to send
I have an existing Perl script that uses the FTP object to send a
I have an XML object that I want to send to my player via
How can I send a an object got it from a bean in a
I want to send array of my own objects to JSP page by request.
I send an AJAX request to my controller . This development done in JSP
Does anybody know how can I send an object, to be more specific a
As near as I can tell, this falls under a you can't do that.

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.