469,299 Members | 2,073 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,299 developers. It's quick & easy.

Web design using JSP with iframe, good or bad?

121 100+
Hello everyone.

My project is to build a online video retailer system (of course just simulation, not for real).

I have been thinking about this for days and already made some researches. According to the requirements, this project must be built by J2EE architecture, therefore the majority of the web pages must be with the .jsp type.

Thinking about the design, I found it pretty useful if you could define a header.jsp and footer.jsp at first and then we you have another page, just use the JSP include tag, as the following sample:

Expand|Select|Wrap|Line Numbers
  1. <html>
  2. <head>
  3. <title>This is another page!</title>
  4. </head>
  5. <body>
  6. <jsp:include page="header.jsp" />
  7. <!-- The main contents go here! -->
  8. <jsp:include page="footer.jsp" />
  9. </body>
It worked, but I wonder if there are some "advanced" approaches that can support refresh ONLY the content section while keep both the header and footer JSPs during the process.

The reason for this is that I am having some good flash files, I made them for the header & footers, so I don't want to reload them every time the content section changes, in order to give the users a consistent view .

BTW, if I want to use an iframe for the content section to divide the contents vertically apart from the menu navigation bar, is it good practice? I learned that using traditional frames are in fact too bad for a project.

Any logical or detailed suggestion will be welcomed and appreciated.

If this is too hard to achieve this functionality, I will go back to use some static images for the headers and footers XD...
Aug 24 '07 #1
3 4137
dmjpro
2,476 2GB
Hello everyone.

My project is to build a online video retailer system (of course just simulation, not for real).

I have been thinking about this for days and already made some researches. According to the requirements, this project must be built by J2EE architecture, therefore the majority of the web pages must be with the .jsp type.

Thinking about the design, I found it pretty useful if you could define a header.jsp and footer.jsp at first and then we you have another page, just use the JSP include tag, as the following sample:

Expand|Select|Wrap|Line Numbers
  1. <html>
  2. <head>
  3. <title>This is another page!</title>
  4. </head>
  5. <body>
  6. <jsp:include page="header.jsp" />
  7. <!-- The main contents go here! -->
  8. <jsp:include page="footer.jsp" />
  9. </body>
It worked, but I wonder if there are some "advanced" approaches that can support refresh ONLY the content section while keep both the header and footer JSPs during the process.

The reason for this is that I am having some good flash files, I made them for the header & footers, so I don't want to reload them every time the content section changes, in order to give the users a consistent view .

BTW, if I want to use an iframe for the content section to divide the contents vertically apart from the menu navigation bar, is it good practice? I learned that using traditional frames are in fact too bad for a project.

Any logical or detailed suggestion will be welcomed and appreciated.

If this is too hard to achieve this functionality, I will go back to use some static images for the headers and footers XD...

You can also do it using Frame or Iframe.
No problem with it.
That's not the server side problem.
This is the client side problem.
So it's your choice what you will use.
The server does not take care what HTML element you are using.
OK.

Kind regards,
Dmjpro.
Aug 24 '07 #2
mattmao
121 100+
Thanks for your clarification!
Aug 25 '07 #3
dmjpro
2,476 2GB
Thanks for your clarification!
You are welcome.
Kind regards,
Dmjpro.
Aug 27 '07 #4

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

3 posts views Thread by Andres Mas Torrecillas | last post: by
98 posts views Thread by Pamel | last post: by
1 post views Thread by Jac | last post: by
7 posts views Thread by Luis Esteban Valencia | last post: by
5 posts views Thread by Chris Kennedy | last post: by
7 posts views Thread by ukrbend | last post: by
1 post views Thread by CARIGAR | last post: by
reply views Thread by zhoujie | last post: by
1 post views Thread by Geralt96 | last post: by
reply views Thread by harlem98 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.