<% jagg.template("menu/primary", function(inputs, outputs, jagg) { %>
<%var reqUrl = request.getRequestURI();
 var inlineUrl=jagg.getAbsoluteUrl("/site/pages/inline-editor.jag");

 var urlPrefix;
 var urlPostfix;

 var encode = require('encode');
 encode = new encode.Encode();
 var tenant = encode.forUriComponent(request.getParameter("tenant"));
 if(tenant != null && tenant != 'null') {urlPrefix="?tenant="+tenant;}else{urlPrefix='';}
 if(tenant != null && tenant != 'null') {urlPostfix="&tenant="+tenant;}else{urlPostfix='';}

%>

<link href="<%=jagg.getAbsoluteUrl(jagg.getThemeFile("lib/bootstrap/css/bootstrap.css"))%>" rel="stylesheet">
<link href="<%=jagg.getAbsoluteUrl(jagg.getThemeFile("lib/bootstrap/css/bootstrap-responsive.css"))%>" rel="stylesheet">
<link rel="shortcut icon" href="<%=jagg.getAbsoluteUrl(jagg.getThemeFile("images/favicon.ico"))%>">
<link rel="apple-touch-icon" href="<%=jagg.getAbsoluteUrl(jagg.getThemeFile("images/apple-touch-icon.png"))%>">
<link rel="apple-touch-icon" sizes="72x72" href="<%=jagg.getAbsoluteUrl(jagg.getThemeFile("images/apple-touch-icon-72x72.png"))%>">
<link rel="apple-touch-icon" sizes="114x114" href="<%=jagg.getAbsoluteUrl(jagg.getThemeFile("images/apple-touch-icon-114x114.png"))%>">

<link href="<%=jagg.getAbsoluteUrl(jagg.getThemeFile("css/localstyles.css"))%>" rel="stylesheet">
<script src="<%=jagg.getAbsoluteUrl(jagg.getThemeFile('lib/jquery-1.7.1.min.js'))%>"></script>




<div class="container-fluid login-header">
          <div class="row-fluid">
              <div class="span2 logo-section">
                  <a class="brand" style="position:absolute;" onclick="jagg.sessionAwareJS({redirect:'<%=jagg.getMappedUrl("/site/pages/index.jag")%><%=urlPrefix%>',e:event})" href="<%=jagg.getMappedUrl("/site/pages/index.jag")%><%=urlPrefix%>"><img src="<%=jagg.getAbsoluteUrl(jagg.getThemeFile("images/logo.png"))%>"
                                                                                                                         alt="API PROVIDER"></a>
              </div>
              <div class="span10 menu-back">
                  <div class="menu-content">
                      <div class="navbar">
                          <div class="navbar-inner">
                              <div class="pull-right">
                              <ul class="nav actions login-sign-up">
                                  <li class="dropdown">
                                    <a id="userMenu"><%if(outputs.user != null && outputs.user != 'null'){%><%=outputs.user.username%><%}%><b class="caret"></b></a>
                                    <ul id="userInfoMenu" class="dropdown-menu">
                                      <li class="userInfoSection">
                                          <%=i18n.localize("logged")%> <h4><%=outputs.user.username%></h4>
                                      </li>
                                      <li class="logout-link-special"><button class="btn btn-danger" onclick="location.href='<%=jagg.getAbsoluteUrl("/site/pages/logout.jag")%><%=urlPrefix%>';"> <%=i18n.localize("logout")%></button></li>
                                    </ul>
                                  </li>
                                </ul>
                                </div>
                          </div>
                      </div>
                  </div>
              </div>
          </div>
      </div>
<%});%>