Resource for fmt tag library not getting loaded in footer JSP

418 views Asked by At

I have 3 JSP with me. header.jsp, center.jsp and footer.jsp. Together they form a landing page.Each of them gets executed in sequence as provided above.

Now am trying to use fmt tld to show some static content on my site.

My code in header.jsp has

<%@ taglib uri="http://java.sun.com/jstl/fmt" prefix="fmt" %>
....
....
<fmt:requestEncoding value="UTF-8" />
<fmt:setLocale value="en" scope="session"/>
<fmt:setBundle basename="content"/>
<fmt:message key="page.header.text"></fmt:message> //this gets displayed

In footer.jsp i have the following:

<%@ taglib uri="http://java.sun.com/jstl/fmt" prefix="fmt" %>
....
....
<fmt:message key="page.header.text"></fmt:message> 

In this case the following is displayed..

???page.footer??? 

means its not able to find the property. If i define the setters which i added in header in the footer then the message comes properly. But ideally i should not be doing that.. what am i doing wrong here for which the bundle is not getting picked up in the footer?

0

There are 0 answers