This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes JSP and the fly likes How to display two different jsp pages in one consolidated jsp page Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "How to display two different jsp pages in one consolidated jsp page" Watch "How to display two different jsp pages in one consolidated jsp page" New topic
Author

How to display two different jsp pages in one consolidated jsp page

Sunni srivastav
Greenhorn

Joined: Feb 15, 2011
Posts: 22

Suppose I have jsp pages named

First.jsp,Second.jsp and Third.jsp.
Then is it possible to display First.jsp and Second.jsp together inside Third.jsp...

I mean,in Html we have Frameset tag to divide the pages into frames..so something simliar to that.


olivier dutranoit
Ranch Hand

Joined: Aug 20, 2011
Posts: 81

Hi,

At the end, everything is HTML...so you can still use your frameset...
Jsp is no html and html is no jsp...
search readings about it...
Gopakumar Naryanan
Ranch Hand

Joined: Jan 15, 2011
Posts: 72

why not!!, use <jsp: include page="first.jsp"/> and <jsp:include page="second.jsp"/>

otherwise <@ page file="./first.jsp"> and <@ page file="./second.jsp"/>

Make sure that, which ever the page being included does not contain <html><body> tags.(They can contain but it will be mess).


Thanks & Regards
Gopakumar
olivier dutranoit
Ranch Hand

Joined: Aug 20, 2011
Posts: 81

sure you can use include etc...
but do not forget that include is totaly something else than a frameset.

in Html we have Frameset tag to divide the pages into frames..so something simliar to that.


it is not similar
Tim Moores
Rancher

Joined: Sep 21, 2011
Posts: 2408
Don't use frames - they're an idea of the Nineties when frameworks for page composition built on the idea of includes didn't exist. Nobody who's serious about web design uses them any more.

Instead, check out frameworks such as SiteMesh, Struts (with Tiles) and Stripes that have concepts of how to aggregate pages from constituent JSP pieces.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to display two different jsp pages in one consolidated jsp page
 
Similar Threads
a session problem
How to Uncheck the checkbox
"jsp:usebean" question
request.getHeader("Referer")
jsppage not rfreshing inIE6.0