You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jspwiki.apache.org by br...@apache.org on 2019/08/21 19:17:56 UTC

[jspwiki] branch master updated: 2.11.0-M5-git-11: [JSPWIKI-1097] , JSP bugs reported by sonarcloud

This is an automated email from the ASF dual-hosted git repository.

brushed pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/jspwiki.git


The following commit(s) were added to refs/heads/master by this push:
     new ba1be24  2.11.0-M5-git-11: [JSPWIKI-1097] , JSP bugs reported by sonarcloud
ba1be24 is described below

commit ba1be247c837d0693118da35663d8f88c7526deb
Author: brushed <di...@gmail.com>
AuthorDate: Wed Aug 21 21:17:39 2019 +0200

    2.11.0-M5-git-11: [JSPWIKI-1097] , JSP bugs reported by sonarcloud
---
 ChangeLog                                          |  8 +++++
 .../src/main/java/org/apache/wiki/Release.java     |  2 +-
 .../src/main/scripts/moo-extend/Element.Extend.js  | 34 +++++++++++-----------
 .../src/main/scripts/util/extend-element.js        |  8 ++---
 .../src/main/scripts/util/extend-function.js       |  1 -
 .../src/main/scripts/wiki-edit/Snipe.Commands.js   |  6 ++--
 .../src/main/scripts/wiki-edit/Snipe.Sections.js   |  2 +-
 .../src/main/scripts/wiki-edit/Snipe.Snips.js      |  4 +--
 .../src/main/scripts/wiki/Wiki.Behaviors.js        | 20 +++++--------
 jspwiki-war/src/main/scripts/wiki/Wiki.js          |  1 -
 .../main/styles/haddock/default/Collapsible.less   |  7 +++--
 .../src/main/styles/haddock/default/Tabs.less      |  7 +++++
 .../src/main/styles/haddock/default/type.less      | 11 +++----
 .../src/main/styles/haddock/default/variables.less |  2 +-
 jspwiki-war/src/main/webapp/Captcha.jsp            | 12 ++++----
 jspwiki-war/src/main/webapp/Error.jsp              | 12 +++++---
 jspwiki-war/src/main/webapp/error/Forbidden.html   |  7 +++--
 .../main/webapp/templates/210/ConflictContent.jsp  | 10 +++----
 .../src/main/webapp/templates/210/DiffTab.jsp      |  8 ++---
 .../main/webapp/templates/default/EditTemplate.jsp |  2 +-
 .../src/main/webapp/templates/default/GroupTab.jsp | 20 +++++--------
 .../webapp/templates/default/UploadTemplate.jsp    |  2 +-
 .../main/webapp/templates/default/ViewTemplate.jsp |  2 +-
 .../templates/default/admin/AdminTemplate.jsp      |  2 +-
 24 files changed, 102 insertions(+), 88 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 7f7eb9d..888681f 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2019-21-08  Dirk Frederickx (brushed AT apache DOT org)
+
+       * 2.11.0-M5-git-11
+
+       * [JSPWIKI-1097] Various smaller JS refactorings, and bugfixes.
+
+       * Clean up several minor JSP bugs reported by sonarcloud.
+
 2019-08-19  Juan Pablo Santos (juanpablo AT apache DOT org)
 
        * 2.11.0-M5-git-10
diff --git a/jspwiki-main/src/main/java/org/apache/wiki/Release.java b/jspwiki-main/src/main/java/org/apache/wiki/Release.java
index 3e93d11..5763e00 100644
--- a/jspwiki-main/src/main/java/org/apache/wiki/Release.java
+++ b/jspwiki-main/src/main/java/org/apache/wiki/Release.java
@@ -72,7 +72,7 @@ public final class Release {
      *  <p>
      *  If the build identifier is empty, it is not added.
      */
-    public static final String     BUILD         = "10";
+    public static final String     BUILD         = "11";
 
     /**
      *  This is the generic version string you should use when printing out the version.  It is of
diff --git a/jspwiki-war/src/main/scripts/moo-extend/Element.Extend.js b/jspwiki-war/src/main/scripts/moo-extend/Element.Extend.js
index 3d55bda..96bb21d 100644
--- a/jspwiki-war/src/main/scripts/moo-extend/Element.Extend.js
+++ b/jspwiki-war/src/main/scripts/moo-extend/Element.Extend.js
@@ -138,23 +138,22 @@ Element.implement({
 
                 //on touch devices, a starttouch also generates a mouseenter on :hover links
                 //however, there is no mouseleave when clicking outside the hover menu
-                //so temporary add a touchend handler on the document to help close the menu
+                //so we need to temporary add a touchend handler on the document to help close the menu
                 document.addEvent("touchend", toggleMenu);
                 toggle.addClass("open");
                 if( onOpen ){ onOpen(); }
 
             } else {
 
-                //close the menu if toggle receives the event or a (touchend-)event is received outside the menu
+                //close the menu if toggle receives the event
+                //or a (touchend-)event is received outside the menu
                 if( (event.target != toggle) && toggle.contains(event.target) ){ return; }
 
                 toggle.removeClass("open");
                 document.removeEvent("touchend", toggleMenu);
 
             }
-            event.preventDefault;
-
-
+            event.preventDefault();
         }
 
         toggle = this.getParent( toggle );
@@ -244,7 +243,7 @@ Element.implement({
     Function onModal
         Open a modal dialog with ""message"".
 
-        Used on clickable elements (input, button, a.href) to get a
+        Used on certain clickable elements (input, button, a.href) to get a
         confirmation prior to executing the default behaviour of the CLICK.
 
     Example:
@@ -273,8 +272,7 @@ Element.implement({
         function onClick(event){
             event.preventDefault();
             modal.openModal( function(){
-                //console.log(self);
-                self.removeEvent("click",onClick).click();
+                self.removeEvent("click", onClick).click();
             });
         }
 
@@ -290,20 +288,22 @@ Element.implement({
 
             modal.ifClass(!event, "active");
             document.body.ifClass(!event, "show-modal");
-            if( event && this.match(".btn-success") ){ callback(); }
+            if( event && this.matches(".btn-success") ){ callback(); }
 
         }
 
+        if( !modal.getElement(".btn.btn-success") ){
+            //add buttons at the bottom of the modal dialog
+            modal.appendChild([
+                "div.modal-footer", [
+                    "button.btn.btn-success", { text: "dialog.confirm".localize() },
+                    "button.btn.btn-danger", { text: "dialog.cancel".localize() }
+                    ]
+                ].slick());
+        }
+
         if( !modal.hasClass(init) ){
 
-            if( !modal.getElement("> .modal-footer") ){
-                modal.grab([
-                    "div.modal-footer", [
-                        "button.btn.btn-success", { text: "Confirm" },  //FIXME: i18n
-                        "button.btn.btn-danger", { text: "Cancel" }
-                        ]
-                    ].slick());
-            }
             //move it just before the backdrop element for easy css styling
             modal.inject( document.getBackdrop(), "before" )
                  .addClass( init )
diff --git a/jspwiki-war/src/main/scripts/util/extend-element.js b/jspwiki-war/src/main/scripts/util/extend-element.js
index 3dd79b2..176a8f3 100644
--- a/jspwiki-war/src/main/scripts/util/extend-element.js
+++ b/jspwiki-war/src/main/scripts/util/extend-element.js
@@ -28,7 +28,6 @@
 $.replaces = function (newElement, existingElement) {
 
     existingElement.parentNode.replaceChild(newElement, existingElement);
-
 }
 
 /*
@@ -44,7 +43,6 @@ $.remove = function (selector, context) {
     });
 }
 
-
 // syntax sugar for element.classList add/remove ; and polyfill for ie11
 // FIMXE better function on element.addClass and [el1,el2...].addClass ...
 $.addClass = function (elements, clazz) {
@@ -59,6 +57,7 @@ $.removeClass = function (elements, clazz) {
 
 //Element.classList mini polyfill for IE11
 if (!!document.createElement('div').classList) {
+
     $.addClass = function (element, clazz) {
         if (!$.hasClass(element, clazz)) {
             element.className = element.className + ' ' + clazz;
@@ -70,12 +69,14 @@ if (!!document.createElement('div').classList) {
 }
 
 $.hasClass = function (element, clazz) {
+
     //return element.classList.contains(clazz)
     return element.matches("." + clazz);
 }
 
 //credit: mootools more
 $.isVisible = function (element) {
+
     var w = element.offsetWidth,
         h = element.offsetHeight;
     return (w == 0 && h == 0) ? false : (w > 0 && h > 0) ? true : element.style.display != 'none';
@@ -106,7 +107,6 @@ $.ifClass = function (element, flag, trueClass, falseClass) {
     return element;
 }
 
-
 /*
 Function: wrapChildren(start, grab)
     This function groups a lists of children, delimited by certain DOM elements.
@@ -175,5 +175,3 @@ $.wrapChildren = function (container, delimitter, wrapper, replaceDelimitter, st
         }
     }
 }
-
-
diff --git a/jspwiki-war/src/main/scripts/util/extend-function.js b/jspwiki-war/src/main/scripts/util/extend-function.js
index 6051f25..0d8433c 100644
--- a/jspwiki-war/src/main/scripts/util/extend-function.js
+++ b/jspwiki-war/src/main/scripts/util/extend-function.js
@@ -34,4 +34,3 @@ $.toFunction = function(o){
     return o instanceof Function ? o : function(){ return o; };
 
 }
-
diff --git a/jspwiki-war/src/main/scripts/wiki-edit/Snipe.Commands.js b/jspwiki-war/src/main/scripts/wiki-edit/Snipe.Commands.js
index 42fba89..98c24db 100644
--- a/jspwiki-war/src/main/scripts/wiki-edit/Snipe.Commands.js
+++ b/jspwiki-war/src/main/scripts/wiki-edit/Snipe.Commands.js
@@ -95,7 +95,7 @@ Snipe.Commands = new Class({
             dlg ? dlg.toggle() : self.action( cmd );
 
             // input fields (eg checkboxes) keep the default behaviour; other click events are disabled
-            if( !this.match("input") ){ event.stop(); }
+            if( !this.matches("input") ){ event.stop(); }
 
 
         });
@@ -189,7 +189,7 @@ Snipe.Commands = new Class({
         //console.log("Commands.action ", command, " value:", value, " btn=", button, " dlg=", dialog);
         //if( button ) button = document.id( button);
 
-        if( button && button.match(".disabled") ){
+        if( button && button.matches(".disabled") ){
 
             //nothing to be done here
 
@@ -230,7 +230,7 @@ Snipe.Commands = new Class({
     */
     createDialog: function( command ){
 
-        var dialog = Function.from( this.dialogs[command] )();
+        var dialog = $.toFunction( this.dialogs[command] )();
 
         //console.log("Snipe.Commands: createDialog() " + command + " ",dialog );
 
diff --git a/jspwiki-war/src/main/scripts/wiki-edit/Snipe.Sections.js b/jspwiki-war/src/main/scripts/wiki-edit/Snipe.Sections.js
index 13849ce..033d00a 100644
--- a/jspwiki-war/src/main/scripts/wiki-edit/Snipe.Sections.js
+++ b/jspwiki-war/src/main/scripts/wiki-edit/Snipe.Sections.js
@@ -214,7 +214,7 @@ Snipe.Sections = new Class({
             if( item.target ){ item = item.target.className; }
 
             //section-2=All, section-1=StartOfPage, section0..section99=rest
-            item = ( item.match( /section=?(-?\d+)/ )||[,-2])[1].toInt();
+            item = parseInt(( item.match( /section=?(-?\d+)/ )||[,-2])[1]);
 
             if( item == -1 ){
 
diff --git a/jspwiki-war/src/main/scripts/wiki-edit/Snipe.Snips.js b/jspwiki-war/src/main/scripts/wiki-edit/Snipe.Snips.js
index a8d3b8e..fcf8e01 100644
--- a/jspwiki-war/src/main/scripts/wiki-edit/Snipe.Snips.js
+++ b/jspwiki-war/src/main/scripts/wiki-edit/Snipe.Snips.js
@@ -56,7 +56,7 @@ Snipe.Snips = new Class({
 
         for( cmd in snips ){
 
-            snip = Function.from( snips[cmd] )( workarea, cmd );
+            snip = $.toFunction( snips[cmd] )( workarea, cmd );
 
             // short format of snip
             if( typeOf(snip) == "string" ){ snip = { snippet:snip }; }
@@ -169,7 +169,7 @@ Snipe.Snips = new Class({
 
                 } else {
 
-                    result = Function.from(suggest)(workarea, caret, fromStart);
+                    result = $.toFunction(suggest)(workarea, caret, fromStart);
 
                 }
 
diff --git a/jspwiki-war/src/main/scripts/wiki/Wiki.Behaviors.js b/jspwiki-war/src/main/scripts/wiki/Wiki.Behaviors.js
index e0d9a92..1080f75 100644
--- a/jspwiki-war/src/main/scripts/wiki/Wiki.Behaviors.js
+++ b/jspwiki-war/src/main/scripts/wiki/Wiki.Behaviors.js
@@ -90,6 +90,9 @@ wiki.once( "img:not(outlink)", function(imgs){
 /*
 Behavior: GraphBars, Progress-bars
 
+%%progress-red-striped 50/%  =>  %%graphBars-progress-red-striped-minv0-maxv100 %%gBar 50/% /%
+%%progress-red-striped 50/75 /%  =>  %%graphBars-progress-red-striped-minv0-maxv75 %%gBar 50/% /%
+
 %%progress 50 /%
 %%progress 50/75 /%
 %%progress-inside 50 /%
@@ -112,13 +115,6 @@ wiki.add("*[class^=progress]", function(element){
     ( element.get("tag") + clazz + "-minv0-maxv" + maxv  ).slick().wraps(element);
     element.className = "gBar";
 
-
-/*
-%%progress-red-striped 50/%  =>  %%graphBars-progress-red-striped-minv0-maxv100 %%gBar 50/% /%
-%%progress-red-striped 50/75 /%  =>  %%graphBars-progress-red-striped-minv0-maxv75 %%gBar 50/% /%
-
-*/
-
     })
 
 /*
@@ -233,20 +229,20 @@ Behavior: Viewer
             element.addClass("viewport").replaces(a);
 
         });
-
     })
-    .add(".maps", function( map ){
+
+
+    .add(".maps,.map", function( map ){
 
         var address = map.textContent.trim(),
-            mapSvc = map.className.replace("-maps","").replace("maps","google"),
-            url = "https://maps.{0}.com/maps?q=".xsubs(mapSvc) + encodeURIComponent( address );
+            //mapSvc = map.className.replace("-maps","").replace(/maps?/,"google"),
+            url = "https://maps.google.com/maps?q=" + encodeURIComponent( address );
 
         Viewer.preload(url, { width: 800, height: 600 }, function( element ){
 
             element.addClass("viewport").replaces(map);
 
         });
-
     });
 
 
diff --git a/jspwiki-war/src/main/scripts/wiki/Wiki.js b/jspwiki-war/src/main/scripts/wiki/Wiki.js
index ef2c1b7..dc0211e 100644
--- a/jspwiki-war/src/main/scripts/wiki/Wiki.js
+++ b/jspwiki-war/src/main/scripts/wiki/Wiki.js
@@ -544,7 +544,6 @@ var Wiki = {
     Function: addEditLinks
         Add to each Section title (h2/h3/h4) a quick edit link.
         FFS: should better move server side
-        FFS: add section #hash to automatically go back to the section being edited
     */
     addEditLinks: function( url ){
 
diff --git a/jspwiki-war/src/main/styles/haddock/default/Collapsible.less b/jspwiki-war/src/main/styles/haddock/default/Collapsible.less
index ec0496a..199ba41 100644
--- a/jspwiki-war/src/main/styles/haddock/default/Collapsible.less
+++ b/jspwiki-war/src/main/styles/haddock/default/Collapsible.less
@@ -128,10 +128,10 @@ DOM structure AFTER:
     //list group: draw nested boxes around groups of list items
     &.list-group {
     	.collapse-btn {
-    		margin-right: @collapse-btn-base;
+    		//margin-right: @collapse-btn-base;
     		&::before {
-				top: -@collapse-btn-base;
-        		left: 0;
+				//top: -@collapse-btn-base;
+        		//left: 0;
 	    	}
     	}
     }
@@ -162,6 +162,7 @@ DOM structure AFTER:
 (end)
 
 */
+div.list-group,
 div[class^=collapsebox] {
     margin-bottom: @line-height-computed;  //copied from contextual boxes from bootstrap
 
diff --git a/jspwiki-war/src/main/styles/haddock/default/Tabs.less b/jspwiki-war/src/main/styles/haddock/default/Tabs.less
index cdb6f06..cd44df6 100644
--- a/jspwiki-war/src/main/styles/haddock/default/Tabs.less
+++ b/jspwiki-war/src/main/styles/haddock/default/Tabs.less
@@ -50,3 +50,10 @@ DOM structure:  ( based on Bootstrap conventions, without [data-toggle=tab] )
 [class^=tab-] *:first-child {
     margin-top:0;
 }
+.tabs {
+	&>h2, &>h3, &>h4 {
+		& > .hashlink, & > .editsection {			//??.label
+			display:none;
+		}
+	}
+}
diff --git a/jspwiki-war/src/main/styles/haddock/default/type.less b/jspwiki-war/src/main/styles/haddock/default/type.less
index 6aac52a..5085772 100644
--- a/jspwiki-war/src/main/styles/haddock/default/type.less
+++ b/jspwiki-war/src/main/styles/haddock/default/type.less
@@ -41,7 +41,7 @@ ol:last-child {
 /*
 Headings:
     The headings h2, h3 and h4 get a {{clear:left}} so they can appear
-    side by side with .commentboxes.
+    side by side with floated-right commentboxes.
 
     The {{.editsection}} and {{.hashlink}} define the styling of the
     [[Edit] and # hash-hover link on each heading.
@@ -147,7 +147,7 @@ br { clear: both; }
 }
 
 //dl { .dl-horizontal; }
-dl dd { margin-left: 2em; }   //reset flat style of bootstrap/type
+dl dd { margin-left: @list-item-indent; }   //reset flat style of bootstrap/type
 
 //copied from bootstrap scaffolding
 .hr {
@@ -377,6 +377,7 @@ pre {
 //inline code: jspwiki uses <tt> ; styles copied from bootstrap/code.less
 tt {
     padding: 2px 4px;
+    position: relative;
     color: @code-color;
     background-color: @code-bg;
     white-space: nowrap;
@@ -418,9 +419,9 @@ ul[class*=list-] > li > [class*="bg-"]:only-child {
 
 
 
-.indent-1 { margin-left: 40px !important; }
-.indent-2 { margin-left: 80px !important; }
-.indent-3 { margin-left: 120px !important; }
+.indent-1 { margin-left:   @list-item-indent !important; }
+.indent-2 { margin-left: 2*@list-item-indent !important; }
+.indent-3 { margin-left: 3*@list-item-indent !important; }
 
 /*
 Links:
diff --git a/jspwiki-war/src/main/styles/haddock/default/variables.less b/jspwiki-war/src/main/styles/haddock/default/variables.less
index d8f4534..130beff 100644
--- a/jspwiki-war/src/main/styles/haddock/default/variables.less
+++ b/jspwiki-war/src/main/styles/haddock/default/variables.less
@@ -63,6 +63,7 @@ images/feather-small.png   wxh  162x286
 // Might as well use the nicest Helvetica you can... http://css-tricks.com/snippets/css/better-helvetica/
 @font-family-sans-serif: "HelveticaNeue-Light", "Helvetica Neue Light", "Helvetica Neue", HelveticaNeue, Segoe UI, Helvetica, Arial, sans-serif;
 @font-size-base: 16px;
+@list-item-indent: 40px;  //default indentation level used by browsers (sometimes this is also 2.5em)
 
 //softer gray-tones
 @pre-bg:                      hsl(240, 14%, 97%); //#f7f7f9;
@@ -155,7 +156,6 @@ images/feather-small.png   wxh  162x286
 @wiki-captcha-bg:      @gray-lighter;
 @wiki-captcha-width:   125px;
 
-
 @collapse-btn-base: .8em;
 
 @pre-scrollable-max-height: 240px;  //bootstrap default is 340px
diff --git a/jspwiki-war/src/main/webapp/Captcha.jsp b/jspwiki-war/src/main/webapp/Captcha.jsp
index 67ad894..83ee201 100644
--- a/jspwiki-war/src/main/webapp/Captcha.jsp
+++ b/jspwiki-war/src/main/webapp/Captcha.jsp
@@ -14,7 +14,7 @@
     "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
     KIND, either express or implied.  See the License for the
     specific language governing permissions and limitations
-    under the License.  
+    under the License.
 --%>
 
 <%@ page import="org.apache.log4j.*" %>
@@ -27,6 +27,7 @@
 <%@ page import="org.apache.commons.lang3.time.StopWatch" %>
 <%@ page errorPage="/Error.jsp" %>
 <%@ taglib uri="http://jspwiki.apache.org/tags" prefix="wiki" %>
+<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
 <%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
 <fmt:setBundle basename="CoreResources"/>
 
@@ -68,7 +69,8 @@
     // Set the content type and include the response content
     response.setContentType( "text/html; charset=" + wiki.getContentEncoding() );
 %>
-<html>
+<!doctype html>
+<html lang="<c:out value='${prefs.Language}' default='en'/>" name="top">
 
 <head>
   <title><wiki:Variable var="applicationname" />: <wiki:PageName /></title>
@@ -88,16 +90,16 @@
           return false;
        }
     }
-    
+
     function i18nAsirra() {
        document.getElementById("asirra_InstructionsTextId").innerHTML = "<fmt:message key="captcha.asirra.please.select" />";
-	   for ( var i = 0; i < 12; i++) 
+	   for ( var i = 0; i < 12; i++)
        {
           document.getElementById("asirra_AdoptMeDiv" + i).getElementsByTagName("a")[0].innerHTML= '<font size="-1">' + '<fmt:message key="captcha.asirra.adopt.me" />' + '</font>' ;
        }
        document.getElementById("asirra_KnobsTable").getElementsByTagName("a")[0].title="<fmt:message key="captcha.asirra.a.get.challenge" />";
        document.getElementById("asirra_KnobsTable").getElementsByTagName("a")[1].title="<fmt:message key="captcha.asirra.a.whatsthis" />";
-       document.getElementById("mainForm").style.display="block"; // show form when i18n is done 
+       document.getElementById("mainForm").style.display="block"; // show form when i18n is done
     }
    </script>
 </head>
diff --git a/jspwiki-war/src/main/webapp/Error.jsp b/jspwiki-war/src/main/webapp/Error.jsp
index 52fc4d4..36fe2f4 100644
--- a/jspwiki-war/src/main/webapp/Error.jsp
+++ b/jspwiki-war/src/main/webapp/Error.jsp
@@ -66,18 +66,22 @@
 %>
 
 <!doctype html>
-<html lang="${prefs.Language}" name="top">
+<html lang="<c:out value='${prefs.Language}' default='en'/>" name="top">
+  <head>
+    <title><wiki:Variable var="applicationname" />: ERROR Page</title>
+  </head>
+
   <body>
    <h3>JSPWiki has detected an error</h3>
 
    <dl>
-      <dt><b>Error Message</b></dt>
+      <dt>Error Message</dt>
       <dd>
          <wiki:Messages div="error" />
       </dd>
-      <dt><b>Exception</b></dt>
+      <dt>Exception</dt>
       <dd><%=realcause.getClass().getName()%></dd>
-      <dt><b>Place where detected</b></dt>
+      <dt>Place where detected</dt>
       <dd><%=FileUtil.getThrowingMethod(realcause)%></dd>
    </dl>
    <p>
diff --git a/jspwiki-war/src/main/webapp/error/Forbidden.html b/jspwiki-war/src/main/webapp/error/Forbidden.html
index bab0fa7..f17b549 100644
--- a/jspwiki-war/src/main/webapp/error/Forbidden.html
+++ b/jspwiki-war/src/main/webapp/error/Forbidden.html
@@ -19,7 +19,9 @@
 
 <!doctype html>
 <html lang="en" name="top">
-  <style>
+  <head>
+    <title><wiki:Variable var="applicationname" />: Forbidden</title>
+    <style>
     body { margin: 3em auto; width:50%; }
     h3 {
       font-family: 'HelveticaNeue-UltraLight', 'Helvetica Neue UltraLight', 'Helvetica Neue', Arial, Helvetica, sans-serif;
@@ -29,7 +31,8 @@
 
       border-bottom: 2px solid black;
     }
-  </style>
+    </style>
+  </head>
   <body>
     <h3>Forbidden</h3>
     <p>
diff --git a/jspwiki-war/src/main/webapp/templates/210/ConflictContent.jsp b/jspwiki-war/src/main/webapp/templates/210/ConflictContent.jsp
index 34a827f..3d6fed5 100644
--- a/jspwiki-war/src/main/webapp/templates/210/ConflictContent.jsp
+++ b/jspwiki-war/src/main/webapp/templates/210/ConflictContent.jsp
@@ -14,7 +14,7 @@
     "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
     KIND, either express or implied.  See the License for the
     specific language governing permissions and limitations
-    under the License.  
+    under the License.
 --%>
 
 <%@ taglib uri="http://jspwiki.apache.org/tags" prefix="wiki" %>
@@ -30,13 +30,13 @@
     <fmt:param><wiki:EditLink><wiki:PageName /></wiki:EditLink></fmt:param>
   </fmt:message>
 </wiki:Tab>
- 
+
 <wiki:Tab id="conflictOther" title='<%=LocaleSupport.getLocalizedMessage(pageContext, "conflict.modified")%>' >
-  <tt><%=pageContext.getAttribute("conflicttext",PageContext.REQUEST_SCOPE)%></tt>      
+  <pre><%=pageContext.getAttribute("conflicttext",PageContext.REQUEST_SCOPE)%></pre>
 </wiki:Tab>
- 
+
 <wiki:Tab id="conflictOwn" title='<%=LocaleSupport.getLocalizedMessage(pageContext, "conflict.yourtext")%>' >
-  <tt><%=pageContext.getAttribute("usertext",PageContext.REQUEST_SCOPE)%></tt>
+  <pre><%=pageContext.getAttribute("usertext",PageContext.REQUEST_SCOPE)%></pre>
 </wiki:Tab>
 
 </wiki:TabbedSection>
\ No newline at end of file
diff --git a/jspwiki-war/src/main/webapp/templates/210/DiffTab.jsp b/jspwiki-war/src/main/webapp/templates/210/DiffTab.jsp
index fc0ced5..17d7f56 100644
--- a/jspwiki-war/src/main/webapp/templates/210/DiffTab.jsp
+++ b/jspwiki-war/src/main/webapp/templates/210/DiffTab.jsp
@@ -14,7 +14,7 @@
     "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
     KIND, either express or implied.  See the License for the
     specific language governing permissions and limitations
-    under the License.  
+    under the License.
 --%>
 
 <%@ page import="org.apache.wiki.tags.InsertDiffTag" %>
@@ -27,8 +27,8 @@
 <fmt:setLocale value="${prefs.Language}" />
 <fmt:setBundle basename="templates.default"/>
 
-<% 
-  WikiContext c = WikiContext.findContext( pageContext );  
+<%
+  WikiContext c = WikiContext.findContext( pageContext );
   List history = c.getEngine().getVersionHistory(c.getPage().getName());
   pageContext.setAttribute( "history", history );
   pageContext.setAttribute( "diffprovider", c.getEngine().getVariable(c,"jspwiki.diffProvider"));
@@ -66,7 +66,7 @@
   </c:if>
 
   <div class="diffbody">
-    <wiki:InsertDiff><i><fmt:message key="diff.nodiff"/></i></wiki:InsertDiff> 
+    <wiki:InsertDiff><p></p><p class="warning"><fmt:message key="diff.nodiff"/></p></wiki:InsertDiff>
   </div>
 </div>
 </form>
diff --git a/jspwiki-war/src/main/webapp/templates/default/EditTemplate.jsp b/jspwiki-war/src/main/webapp/templates/default/EditTemplate.jsp
index 1f43236..2b6f10e 100644
--- a/jspwiki-war/src/main/webapp/templates/default/EditTemplate.jsp
+++ b/jspwiki-war/src/main/webapp/templates/default/EditTemplate.jsp
@@ -45,7 +45,7 @@
 
 <body class="context-<wiki:Variable var='requestcontext' />" >
 
-<div class="container${prefs.Layout=='fluid' ? '-fluid' : ''} ${prefs.Orientation}">
+<div class="container${prefs.Layout=='fixed' ? ' ' : '-fluid ' } ${prefs.Orientation}">
 
   <wiki:Include page="Header.jsp" />
   <div class="content" data-toggle="li#menu,.sidebar>.close" >
diff --git a/jspwiki-war/src/main/webapp/templates/default/GroupTab.jsp b/jspwiki-war/src/main/webapp/templates/default/GroupTab.jsp
index 8c39a57..3fb4984 100644
--- a/jspwiki-war/src/main/webapp/templates/default/GroupTab.jsp
+++ b/jspwiki-war/src/main/webapp/templates/default/GroupTab.jsp
@@ -128,22 +128,18 @@
         group = groupMgr.getGroup( name );
         members = group.members();
         Arrays.sort( members, new PrincipalComparator() );
-
-        membersAsString = new StringBuffer();
-        for ( int i = 0; i < members.length; i++ )
-        {
-          membersAsString.append( members[i].getName().trim() );
-          if( i+1 < members.length ){ membersAsString.append( ", " ); }
-        }
-
+        pageContext.setAttribute("members", members);
     %>
     <c:set var="group" value="<%= group %>" />
-    <c:set var="members" value="<%= membersAsString %>" />
     <tr class="${param.group == group.name ? 'highlight' : ''}">
       <%--<td><wiki:Link jsp='Group.jsp'><wiki:Param name='group' value='${group.name}'/>${group.name}</wiki:Link></td>--%>
-      <td><c:if test="${group.name =='Admin'}"><span class="icon-unlock-alt"></span></c:if> ${group.name}</td>
-      <td>${members}</td>
-
+      <td><c:if test="${group.name =='Admin'}"><span class="icon-unlock-alt"></span> </c:if>${group.name}</td>
+      <td>
+        <c:forEach items="${members}" var="member" varStatus="iterator">
+          <c:if test="${iterator.index > 0}">, </c:if>
+          ${member.name}
+        </c:forEach>
+      </td>
       <td><fmt:formatDate value="${group.created}" pattern="${prefs.DateFormat}" timeZone="${prefs.TimeZone}" /></td>
       <td>${group.creator}</td>
       <td><fmt:formatDate value="${group.lastModified}" pattern="${prefs.DateFormat}" timeZone="${prefs.TimeZone}" /></td>
diff --git a/jspwiki-war/src/main/webapp/templates/default/UploadTemplate.jsp b/jspwiki-war/src/main/webapp/templates/default/UploadTemplate.jsp
index eebbe55..4129fa8 100644
--- a/jspwiki-war/src/main/webapp/templates/default/UploadTemplate.jsp
+++ b/jspwiki-war/src/main/webapp/templates/default/UploadTemplate.jsp
@@ -35,7 +35,7 @@
 
 <body class="context-<wiki:Variable var='requestcontext' />">
 
-<div class="container${prefs.Layout=='fixed' ? '' : '-fluid' } ${prefs.Orientation} fixed-header">
+<div class="container${prefs.Layout=='fixed' ? ' ' : '-fluid ' } ${prefs.Orientation} fixed-header">
 
   <wiki:Include page="Header.jsp" />
 
diff --git a/jspwiki-war/src/main/webapp/templates/default/ViewTemplate.jsp b/jspwiki-war/src/main/webapp/templates/default/ViewTemplate.jsp
index 6d1f939..d118853 100644
--- a/jspwiki-war/src/main/webapp/templates/default/ViewTemplate.jsp
+++ b/jspwiki-war/src/main/webapp/templates/default/ViewTemplate.jsp
@@ -47,7 +47,7 @@
 
 <body class="context-<wiki:Variable var='requestcontext' default='' />">
 
-<div class="container${prefs.Layout=='fixed' ? '' : '-fluid' } ${prefs.Orientation} fixed-header">
+<div class="container${prefs.Layout=='fixed' ? ' ' : '-fluid ' } ${prefs.Orientation} fixed-header">
 
   <wiki:Include page="Header.jsp" />
 
diff --git a/jspwiki-war/src/main/webapp/templates/default/admin/AdminTemplate.jsp b/jspwiki-war/src/main/webapp/templates/default/admin/AdminTemplate.jsp
index f222b5b..333b3ad 100644
--- a/jspwiki-war/src/main/webapp/templates/default/admin/AdminTemplate.jsp
+++ b/jspwiki-war/src/main/webapp/templates/default/admin/AdminTemplate.jsp
@@ -37,7 +37,7 @@
 <div id="page" >
 <h1>JSPWiki Administration</h1>
 <div class="information">Not all things can be configured here.  Some things need to be configured
-in your <tt>jspwiki.properties</tt> file.</div>
+in your <code>jspwiki.properties</code> file.</div>
 
 <%
     WikiEngine wiki = WikiEngine.getInstance( getServletConfig() );