[sword-svn] r314 - trunk/webapp/layouts

scribe at www.crosswire.org scribe at www.crosswire.org
Thu Oct 30 13:32:50 MST 2008


Author: scribe
Date: 2008-10-30 13:32:48 -0700 (Thu, 30 Oct 2008)
New Revision: 314

Modified:
   trunk/webapp/layouts/base-layout.jsp
Log:
added lang attribute dynamically pulled from user selection


Modified: trunk/webapp/layouts/base-layout.jsp
===================================================================
--- trunk/webapp/layouts/base-layout.jsp	2008-10-29 00:21:00 UTC (rev 313)
+++ trunk/webapp/layouts/base-layout.jsp	2008-10-30 20:32:48 UTC (rev 314)
@@ -3,16 +3,9 @@
 <%@ taglib uri="/WEB-INF/lib/crosswire-i18n.tld" prefix="t" %>
 
 <%@ page import="java.util.Vector" %>
-
-<?xml version="1.0" encoding="utf-8"?>
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-US" lang="en-US">
-
-<head profile="http://www.w3.org/2000/08/w3c-synd/#">
-<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
-	<title><t:t>OSIS Web: </t:t><tiles:getAsString name="title"/></title>
-
 <%
+	String lang = (String)session.getAttribute("lang");
+	if (lang == null) lang = "en-US";
 	String prefStyle = (String)session.getAttribute("PrefStyle");
 	Vector styleNames = (Vector)session.getAttribute("styleNames");
 	Vector styleFiles = (Vector)session.getAttribute("styleFiles");
@@ -26,6 +19,15 @@
 	else searchTerm = "";
 %>
 
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<%= lang %>" lang="<%= lang %>">
+
+<head profile="http://www.w3.org/2000/08/w3c-synd/#">
+<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
+	<title><t:t>OSIS Web: </t:t><tiles:getAsString name="title"/></title>
+
+
 <link rel="stylesheet" type="text/css" media="all" title="<%= styleName %>" href="<%= styleFile %>"  />
 
 <% for (int i = 0; i < styleNames.size(); i++) { %>




More information about the sword-cvs mailing list