Commit feade8a3 authored by Matija Obreza's avatar Matija Obreza
Browse files

Extracted header to separate file

parent ad6b3268
...@@ -48,62 +48,7 @@ ...@@ -48,62 +48,7 @@
<div id="wrap"> <div id="wrap">
<div class="container"> <div class="container">
<div id="header"> <%@include file="header.jsp" %>
<div class="clearfix">
<div class="pull-left">
<a href="<c:url value="/" />"><img style="height: 40px;" src="<c:url value="/html/images/logo2.png" />" /></a>
</div>
<!-- <h4 class="pull-left"><spring:message code="sample.message.welcome"/></h4> -->
<div class="pull-right searcher" style="margin-top: 5px;">
<form class="form-inline" method="get" action="<c:url value="/search" />">
<div class="input-group">
<input type="text" name="q" class="form-control" placeholder="<spring:message code="search.input.placeholder" />"/>
<span class="input-group-btn">
<button type="submit" class="btn notimportant"><spring:message code="search.button.label" /></button>
</span>
</div>
</form>
</div>
<div class="navbar pull-right">
<div class="nav-collapse">
<ul class="nav">
<li class="dropdown"><a class="dropdown-toggle" data-toggle="dropdown"> <spring:message code="sample.message.locale.${pageContext.response.locale}" /> <b class="caret"></b>
</a>
<ul class="dropdown-menu">
<li><a href="?lang=en"><spring:message code="sample.message.locale.en" /></a></li>
<li><a href="?lang=sl"><spring:message code="sample.message.locale.sl" /></a></li>
</ul></li>
</ul>
</div>
</div>
<div class="navbar pull-right">
<sec:authorize access="isAnonymous()">
<ul class="nav">
<li>
<a href="<c:url value="/login" />">Login</a><%-- or <a href="<c:url value="/registration" />"><spring:message code="user.create-new-account" /></a> --%>
</li>
</ul>
</sec:authorize>
<sec:authorize access="isAuthenticated()">
<ul class="nav">
<li class="dropdown"><a class="dropdown-toggle" data-toggle="dropdown" title="<spring:message code="sample.message.change.locale"/>"> You are <b>${user.username}</b> <b class="caret"></b>
</a>
<ul class="dropdown-menu">
<sec:authorize access="hasRole('ADMINISTRATOR')">
<li><a href="<c:url value="/admin/" />">Administation</a></li>
</sec:authorize>
<li><a href="<c:url value="/profile" />"><spring:message code="user.pulldown.profile" /></a></li>
<li><a href="<c:url value="/logout" />"><spring:message code="user.pulldown.logout" /></a></li>
</ul></li>
</ul>
</sec:authorize>
</div>
</div>
</div>
<%@include file="menu.jsp" %> <%@include file="menu.jsp" %>
......
<%@include file="/WEB-INF/jsp/init.jsp"%>
<div id="header">
<div class="clearfix">
<div class="pull-left">
<a href="<c:url value="/" />"><img style="height: 40px;" src="<c:url value="/html/images/logo2.png" />" /></a>
</div>
<div class="pull-right searcher" style="margin-top: 5px;">
<form class="form-inline" method="get" action="<c:url value="/search" />">
<div class="input-group">
<input type="text" name="q" class="form-control" placeholder="<spring:message code="search.input.placeholder" />" /> <span class="input-group-btn">
<button type="submit" class="btn notimportant">
<spring:message code="search.button.label" />
</button>
</span>
</div>
</form>
</div>
<div class="notimportant navbar pull-right">
<div class="nav-collapse">
<ul class="nav">
<li class="dropdown"><a class="dropdown-toggle" data-toggle="dropdown"> <spring:message code="sample.message.locale.${pageContext.response.locale}" /> <b class="caret"></b>
</a>
<ul class="dropdown-menu">
<li><a href="?lang=en"><spring:message code="sample.message.locale.en" /></a></li>
<li><a href="?lang=sl"><spring:message code="sample.message.locale.sl" /></a></li>
</ul></li>
</ul>
</div>
</div>
<div class="notimportant navbar pull-right">
<sec:authorize access="isAnonymous()">
<ul class="nav">
<li><a href="<c:url value="/login" />">Login</a>
<%-- or <a href="<c:url value="/registration" />"><spring:message code="user.create-new-account" /></a> --%></li>
</ul>
</sec:authorize>
<sec:authorize access="isAuthenticated()">
<ul class="nav">
<li class="dropdown"><a class="dropdown-toggle" data-toggle="dropdown" title="<spring:message code="sample.message.change.locale"/>"> You are <b>${user.username}</b> <b class="caret"></b>
</a>
<ul class="dropdown-menu">
<sec:authorize access="hasRole('ADMINISTRATOR')">
<li><a href="<c:url value="/admin/" />">Administation</a></li>
</sec:authorize>
<li><a href="<c:url value="/profile" />"><spring:message code="user.pulldown.profile" /></a></li>
<li><a href="<c:url value="/logout" />"><spring:message code="user.pulldown.logout" /></a></li>
</ul></li>
</ul>
</sec:authorize>
</div>
</div>
</div>
\ No newline at end of file
...@@ -48,24 +48,7 @@ ...@@ -48,24 +48,7 @@
<div id="wrap"> <div id="wrap">
<div class="container"> <div class="container">
<div id="header"> <%@include file="header.jsp" %>
<div class="clearfix">
<div class="pull-left">
<a href="<c:url value="/" />"><img style="height: 30px" src="<c:url value="/html/images/logo2.png" />" /></a>
</div>
<div class="pull-right" id="header-searcher">
<form class="form-inline" method="get" action="<c:url value="/search" />">
<div class="input-group">
<input type="text" name="q" class="form-control" placeholder="<spring:message code="search.input.placeholder" />"/>
<span class="input-group-btn">
<button type="submit" class="btn"><spring:message code="search.button.label" /></button>
</span>
</div>
</form>
</div>
</div>
</div>
<%@include file="menu.jsp" %> <%@include file="menu.jsp" %>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment