File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes HTML, CSS and JavaScript and the fly likes Ajax Query related to request and response Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "Ajax Query related to request and response" Watch "Ajax Query related to request and response" New topic
Author

Ajax Query related to request and response

suneel kota
Greenhorn

Joined: Jun 06, 2006
Posts: 24
Hi all,

I am using ajax in my application, thing is that when i need to pass ajax response to another jsp page.

Description:
I am calling a servlet with an ajax request from login.jsp, which is returning a data in xml file. but i need to show this data in another jsp called employee.jsp page.

how can i proceed to get above requirement in ajax..

Thanks in advance..

Regards
SuneelKota
Eric Pascarello
author
Rancher

Joined: Nov 08, 2001
Posts: 15376
    
    6
Not sure why you would use Ajax to do this if you are not on the same page.

Eric
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61413
    
  67

Concur with Eric. if you need the XML data in another page, why aren't you making the Ajax call from that page?


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
suneel kota
Greenhorn

Joined: Jun 06, 2006
Posts: 24
Hi Eric,

Thing is that when ever user enters username and password in login page. i need to call a service through ajax request and response should go to employee.jsp page.. Here we are using complete ajax request to call a servlet/service..


Regards
SuneelKota
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61413
    
  67

The whole point of Ajax is to make a request and to return the response to the same page. If that's not what you're doing, Ajax is not the correct means.

If you need to respond to another page, just submit the form to the next page.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Ajax Query related to request and response