SunQuest
           Java Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming LanguagesJava Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
Generate data entry and reporting .NET Web apps in minutes, straight from your database. Read our FREE whitepaper “Build Web 2.0 Applications Without Hand-Coding” Download now!
  #1  
Old September 17th, 2002, 04:27 AM
EHendriks EHendriks is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2002
Location: Amersfoort, The Netherlands
Posts: 10 EHendriks User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 37 sec
Reputation Power: 0
Question Including another page in a jsp

I want to include a footer-file in every other webpage. The default name of the footer file is for example footer.jsp.

In some cases, a specific customer has his specific version of a page. The pagename in that case is the default name extended with a string like "_XX"; example: Footer_XX.jsp.

The pagename postfix is set in a session variable (and can be empty).

At the end of every page, the include directive should look something like this: include file = Filename + the value of the seesion-variable postfix + .jsp

I can't get this to work... any suggestions?

Erwin

Reply With Quote
  #2  
Old September 17th, 2002, 05:47 AM
kittykiller's Avatar
kittykiller kittykiller is offline
Golden Member =p
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jul 2002
Location: Final Frontier
Posts: 9 kittykiller User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
<jsp:include page="footer.jsp" flush="true"/> is the code...

i have not seen any variation in this in terms of passing dynamic page names to it...

there are other methods, i am sure this will help you:

http://developer.java.sun.com/devel...rogramming/jsp/

Reply With Quote
  #3  
Old September 17th, 2002, 12:21 PM
bricker42 bricker42 is offline
Moderator =(8^(|)
Dev Shed Intermediate (1500 - 1999 posts)
 
Join Date: Feb 2002
Location: Sacramento, CA
Posts: 1,710 bricker42 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 20 m 38 sec
Reputation Power: 8
Send a message via AIM to bricker42
Code:
<%
String footerPage = "footer";
footerPage += session.getAttribute( "custFootId" );
footerPage += ".jsp";
%>

<jsp:include page="<%=footerPage%>" flush="true"/>

Reply With Quote
  #4  
Old September 19th, 2002, 03:41 AM
EHendriks EHendriks is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2002
Location: Amersfoort, The Netherlands
Posts: 10 EHendriks User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 37 sec
Reputation Power: 0
Thanks again, Brikcker42

Yet again it's You who's helping me out...

Erwin

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming LanguagesJava Help > Including another page in a jsp


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 6 hosted by Hostway