Update of
/var/cvs/contributions/CMSContainer/cmsc/edit-webapp/src/webapp/editors
In directory james.mmbase.org:/tmp/cvs-serv5136
Modified Files:
index.jsp
Log Message:
CMSC-723,Title of CMSc while changing languages,when index.jsp loaded, it will
be bundled to make sure the title get bundled.
See also:
http://cvs.mmbase.org/viewcvs/contributions/CMSContainer/cmsc/edit-webapp/src/webapp/editors
See also: http://www.mmbase.org/jira/browse/CMSC-723
Index: index.jsp
===================================================================
RCS file:
/var/cvs/contributions/CMSContainer/cmsc/edit-webapp/src/webapp/editors/index.jsp,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -b -r1.14 -r1.15
--- index.jsp 9 Jun 2008 16:18:23 -0000 1.14
+++ index.jsp 11 Jun 2008 06:34:30 -0000 1.15
@@ -2,11 +2,11 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">
<[EMAIL PROTECTED] file="globals.jsp" %>
<mm:import externid="bottomurl" from="parameters">dashboard.jsp</mm:import>
+
<mm:cloud loginpage="login.jsp" rank="basic user">
<mm:cloudinfo type="user" id="username" write="false"/>
<mm:listnodes type="user" constraints="username='${username}'">
<mm:field name="language" id="language" write="false"/>
-
<c:if test="${empty language}">
<c:set var="language" value="<%=request.getHeader ( "Accept-Language"
)%>"/>
<c:if test="${fn:length(language) > 2}">
@@ -14,12 +14,13 @@
</c:if>
<mm:setfield name="language">${language}</mm:setfield>
</c:if>
+
</mm:listnodes>
- <fmt:setLocale value="${language}" scope="session"/>
- <fmt:setBundle basename="cmsc" scope="request" /> <%-- Reload the resource
bundle again for JSTL --%>
+
<mm:write referid="language" jspvar="lang" vartype="String">
- <% request.getSession().setAttribute("org.apache.struts.action.LOCALE",
new Locale(lang));%>
+ <%request.getSession().setAttribute("org.apache.struts.action.LOCALE",
new Locale(lang));%>
+
</mm:write>
</mm:cloud>
@@ -28,6 +29,8 @@
This code sets the locale for all editors --%>
<mm:locale language="${language}">
<mm:cloud loginpage="login.jsp" rank="basic user">
+ <fmt:setLocale value="${language}" scope="session"/>
+ <fmt:bundle basename="cmsc">
<html:html xhtml="true">
<head><title><fmt:message key="editors.title" /></title>
<link rel="icon" href="<cmsc:staticurl page='/favicon.ico' />"
type="image/x-icon" />
@@ -44,5 +47,7 @@
<frame src="footer.jsp" name="footerpane" frameborder="0"
scrolling="no"/>
</frameset>
</html:html>
+ </fmt:bundle>
</mm:cloud>
</mm:locale>
\ No newline at end of file
+
_______________________________________________
Cvs mailing list
[email protected]
http://lists.mmbase.org/mailman/listinfo/cvs