This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Web Component Certification (SCWCD/OCPJWCD) and the fly likes Getting JSP's HTML output inside the same JSP Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Certification » Web Component Certification (SCWCD/OCPJWCD)
Bookmark "Getting JSP Watch "Getting JSP New topic
Author

Getting JSP's HTML output inside the same JSP

Kingsly Theodar
Greenhorn

Joined: Feb 21, 2004
Posts: 19
Is there any way of getting the html output of a JSP.

I would like to consume the string(HTML output), after extracting it out of the PrintWriter object.

Inspecting the Servlet API, I was not able to figure out a way.

Is using servlet's out.println the only way?!

Please help.

Thanks in advance,
T.Kingsly
Frederic Esnault
Ranch Hand

Joined: Feb 13, 2006
Posts: 284
I'm not sure I understand what you want to do. Can you clarify, please?


SCJP 5 - SCWCD 1.4 - SCBCD 1.3 - Certification study documents/resources: http://esnault.frederic.free.fr/certification
Narendra Dhande
Ranch Hand

Joined: Dec 04, 2004
Posts: 950
Hi,

I think you want to consume the respons generated by the JSP page before displaying to browser. Look at the filters, it may useful to you.

Thanks


Narendra Dhande
SCJP 1.4,SCWCD 1.4, SCBCD 5.0, SCDJWS 5.0, SCEA 5.0
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Getting JSP's HTML output inside the same JSP
 
Similar Threads
passing a variable from html/jsp to javascript
JSP output to file
Need help in EL and JSP
Formatted Output in HTML Tables
jsp to xml