Commit f130c6a2fcef3523acfe76c25cf98f6881788cb6

Authored by jcartign
1 parent 5cf411ba

Removing boostrap and including page title as variable

src/main/webapp/WEB-INF/pages/footer.jsp
1 -<script src="/webjars/bootstrap/js/bootstrap.min.js"></script>  
2 <script src="/webjars/jquery/jquery.min.js"></script> 1 <script src="/webjars/jquery/jquery.min.js"></script>
3 </body> 2 </body>
4 </html> 3 </html>
src/main/webapp/WEB-INF/pages/header.jsp
@@ -4,7 +4,5 @@ @@ -4,7 +4,5 @@
4 <meta charset="utf-8"> 4 <meta charset="utf-8">
5 <meta http-equiv="X-UA-Compatible" content="IE=edge"> 5 <meta http-equiv="X-UA-Compatible" content="IE=edge">
6 <meta name="viewport" content="width=device-width, initial-scale=1"> 6 <meta name="viewport" content="width=device-width, initial-scale=1">
7 - <title>Title</title>  
8 -  
9 - <link href="/webjars/bootstrap/css/bootstrap.min.css" rel="stylesheet"/> 7 + <title><%= request.getAttribute("pageTitle") %></title>
10 </head> 8 </head>
src/main/webapp/WEB-INF/pages/login.jsp
1 <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> 1 <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
2 <%@ page contentType="text/html;charset=UTF-8" language="java" %> 2 <%@ page contentType="text/html;charset=UTF-8" language="java" %>
3 -<jsp:include page="header.jsp"/> 3 +
  4 +<jsp:include page="header.jsp">
  5 + <jsp:param name="pageTitle" value="Login page"/>
  6 +</jsp:include>
  7 +
4 <c:url value="/login" var="loginUrl"/> 8 <c:url value="/login" var="loginUrl"/>
5 <form action="${loginUrl}" method="post"> 9 <form action="${loginUrl}" method="post">
6 <b><c:out value="${message}"></c:out></b> 10 <b><c:out value="${message}"></c:out></b>
src/main/webapp/WEB-INF/pages/newUser.jsp
1 <%@ page contentType="text/html" pageEncoding="UTF-8" %> 1 <%@ page contentType="text/html" pageEncoding="UTF-8" %>
2 <%@ taglib uri="http://www.springframework.org/tags/form" prefix="form" %> 2 <%@ taglib uri="http://www.springframework.org/tags/form" prefix="form" %>
3 <%@ taglib uri="http://www.springframework.org/tags" prefix="spring" %> 3 <%@ taglib uri="http://www.springframework.org/tags" prefix="spring" %>
4 -<jsp:include page="header.jsp"/> 4 +
  5 +<jsp:include page="header.jsp">
  6 + <jsp:param name="pageTitle" value="New user page"/>
  7 +</jsp:include>
  8 +
5 <h1><spring:message code="new.user.main.header"/></h1> 9 <h1><spring:message code="new.user.main.header"/></h1>
6 <form:form commandName="userForm" method="POST"> 10 <form:form commandName="userForm" method="POST">
7 <table> 11 <table>
src/main/webapp/WEB-INF/pages/viewUsers.jsp
1 <%@ page contentType="text/html" pageEncoding="UTF-8" %> 1 <%@ page contentType="text/html" pageEncoding="UTF-8" %>
2 <%@ taglib uri="http://www.springframework.org/tags" prefix="spring" %> 2 <%@ taglib uri="http://www.springframework.org/tags" prefix="spring" %>
3 <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> 3 <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
4 -<jsp:include page="header.jsp"/> 4 +
  5 +<jsp:include page="header.jsp">
  6 + <jsp:param name="pageTitle" value="View users page"/>
  7 +</jsp:include>
  8 +
5 <h1><spring:message code="view.users.main.header"/></h1> 9 <h1><spring:message code="view.users.main.header"/></h1>
6 10
7 <h4><spring:message code="view.users.greetings"/> ${userSession.username} !</h4> 11 <h4><spring:message code="view.users.greetings"/> ${userSession.username} !</h4>