File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes HTML, CSS and JavaScript and the fly likes retrieve JSON from servlet 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 "retrieve JSON from servlet" Watch "retrieve JSON from servlet" New topic

retrieve JSON from servlet

Carl Jenkins
Ranch Hand

Joined: Feb 19, 2006
Posts: 39
Hey all -

I am trying to get my Ajax (prototype library) application working. The issue I have is that the respnoseText displays the entire html page...

This is the call to the url I just want to display the JSON string for now...

The following is in the Servlet. I know the request stuff looks weird. That is because they use a proprietary tool here and that is how I get to the Request.

Any help would be great - thanks.
Lester Burnham

Joined: Oct 14, 2008
Posts: 1337
What is "the entire html page"? What do you think should be returned, and what is actually being returned?
Bear Bibeault
Author and ninkuma

Joined: Jan 10, 2002
Posts: 62488

Are you saying that's what displayed in the alert differs from what's being written to the response?

[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
I agree. Here's the link:
subject: retrieve JSON from servlet