User manager to properly handle authenticated users with no authorization
[controller.git] / opendaylight / web / root / src / main / resources / WEB-INF / jsp / error.jsp
index 86625854d1e09d1ec1d392854566bb98b2b91fa4..d288969c0a4680091f53a4165122c37ed5079033 100644 (file)
@@ -1,18 +1,27 @@
 <%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
+<%@ page import="java.net.URL" %>
 <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
 
 <!DOCTYPE html>
 <html>
   <head>
     <meta charset="utf-8">
-    <title>OpenDaylight - Error</title>
 
     <!-- Bootstrap CSS - 1 -->
     <link href="/css/bootstrap.min.css" rel="stylesheet" media="screen">
     
     <!-- Login CSS - 2 -->
     <link rel="stylesheet/less" type="text/css" href="/css/login.less">
-    
+
+<c:set var="title" value="OpenDaylight login error" scope="application"/>
+<%
+    String filePath = "/WEB-INF/jsp/customerror.jsp"; 
+       URL fileURL = pageContext.getServletContext().getResource(filePath);
+       if(fileURL!=null) {
+%>
+         <jsp:include page="<%=filePath%>" flush="true"/>
+<% } %>
+       <title>${title}</title>
     <!-- Bootstrap JS - 1 -->
     <script src="/js/bootstrap.min.js"></script>
     
@@ -32,7 +41,7 @@
        <div class="login-form">
          <div id="logo"></div>
            <fieldset>
-            <p>Your session has timed out or there was an error.<p>
+            <p>Login failed or session might have timed out.<p>
             <p>Please go back to the login page and try again.</p>
             <br/>
              <button class="btn btn-primary" type="submit" value="Log In" >Go To Login Page</button>
@@ -42,4 +51,4 @@
   </div> 
   </form>
 </body>
-</html>
\ No newline at end of file
+</html>