anchor.diff:  <body>
   
   <%
  -    Configuration configuration = Aksess.getConfiguration();
  -    String logfile = configuration.getString("logfile.path", configuration.getApplicationDirectory() + "/logs/aksess.log");
  -
  -    RequestParameters param = new RequestParameters(request);
  -
  -
  -    int maxLines = param.getInt("maxLines");
  -    if (maxLines <= 0) {
  -        maxLines = 400;
  -    }
   %>
   
   
  
positive.code:     Vis antall linjer (fra slutten) <input type="text" name="maxLines" value="<%=maxLines%>">
      <input type="submit" value="Vis">
  
      <table border="0">
  
  
          <%
              if (securitySession.isUserInRole(Aksess.getAdminRole())) {
                  File src = new File(logfile);
  
                  BufferedReader reader = new BufferedReader(new FileReader(src));
                  String[] lines = new String[maxLines];
                  int lastNdx = 0;
                  for (String line=reader.readLine(); line != null; line=reader.readLine()) {
                      if (lastNdx == lines.length) {
                          lastNdx = 0;
                      }
                      lines[lastNdx++] = line;
                  }
  
                  for (int ndx=lastNdx; ndx != lastNdx-1; ndx++) {
                      if (ndx == lines.length) {
                          ndx = 0;
                      }
  
                      String clz = "odd";
                      if (ndx % 2 == 0) {
                          clz = "even";
                      }
  
                      if (lines[ndx] != null) {
                          out.write("<tr class=\"" + clz + "\"><td>" + lines[ndx] + "</td></tr>");
                      }
                  }
  
                  reader.close();
  
                  src = null;
              }
          %>
      </table>
  </form>
  
negative.code: 
  <%
      SecuritySession securitySession = SecuritySession.getInstance(request);
  
      if (!securitySession.isUserInRole(Aksess.getAdminRole())) {
          return;
      }
  
      Configuration configuration = Aksess.getConfiguration();
      String logfile = configuration.getString("logfile.path", configuration.getApplicationDirectory() + "/logs/aksess.log");
  
      RequestParameters param = new RequestParameters(request);
  
  
      File src = new File(logfile);
      BufferedReader reader = new BufferedReader(new FileReader(src));
  
      boolean download = param.getBoolean("download", false);
      if (download) {
          response.setContentType("text/plain");
          response.addHeader("Content-Disposition", "attachment; filename=\"aksess.log\"");
      }
  
      int maxLines = param.getInt("maxLines");
      if (maxLines <= 0) {
          maxLines = 400;
      }
  
      String[] lines = new String[maxLines];
      int lastNdx = 0;
      for (String line=reader.readLine(); line != null; line=reader.readLine()) {
          if (download) {
              out.write(line);
          } else {
              if (lastNdx == lines.length) {
                  lastNdx = 0;
              }
              lines[lastNdx++] = line;
          }
      }
      reader.close();
  
      src = null;
  
      if (download) {
          return;
      }
  %>
  <html>
  <head>
  