Index: /FCKeditor.Java/branches/2.4/src/main/webapp/jsp/sample01.jsp
===================================================================
--- /FCKeditor.Java/branches/2.4/src/main/webapp/jsp/sample01.jsp	(revision 1481)
+++ /FCKeditor.Java/branches/2.4/src/main/webapp/jsp/sample01.jsp	(revision 1482)
@@ -1,2 +1,3 @@
+<?xml version="1.0" encoding="UTF-8" ?>
 <%@ page language="java" contentType="text/html; charset=UTF-8"
 	pageEncoding="UTF-8" import="net.fckeditor.*"%>
@@ -21,6 +22,6 @@
  * == END LICENSE ==
 --%>
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
 <html xmlns="http://www.w3.org/1999/xhtml">
 	<head>
@@ -45,6 +46,6 @@
 		<ul>
 			<li>Browser is compatible: <%out.print(fckEditor.isCompatibleBrowser());%></li>
-			<li>User is enabled for file browsing: <%out.print(fckEditor.isEnabledForFileBrowsing());%>
-			<li>User is enabled for file upload: <%out.print(fckEditor.isEnabledForFileUpload());%>
+			<li>User is enabled for file browsing: <%out.print(fckEditor.isEnabledForFileBrowsing());%></li>
+			<li>User is enabled for file upload: <%out.print(fckEditor.isEnabledForFileUpload());%></li>
 		</ul>
 		<hr />
Index: /FCKeditor.Java/branches/2.4/src/main/webapp/jsp/sample02.jsp
===================================================================
--- /FCKeditor.Java/branches/2.4/src/main/webapp/jsp/sample02.jsp	(revision 1481)
+++ /FCKeditor.Java/branches/2.4/src/main/webapp/jsp/sample02.jsp	(revision 1482)
@@ -1,53 +1,56 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<%@ page language="java" contentType="text/html; charset=UTF-8"
+	pageEncoding="UTF-8" %>
 <%@ taglib uri="http://www.fckeditor.net/tags" prefix="FCK" %>
-<!--
+<%--
  * FCKeditor - The text editor for Internet - http://www.fckeditor.net
  * Copyright (C) 2003-2008 Frederico Caldeira Knabben
- * 
+ *
  * == BEGIN LICENSE ==
- * 
+ *
  * Licensed under the terms of any of the following licenses at your
  * choice:
- * 
+ *
  *  - GNU General Public License Version 2 or later (the "GPL")
  *    http://www.gnu.org/licenses/gpl.html
- * 
+ *
  *  - GNU Lesser General Public License Version 2.1 or later (the "LGPL")
  *    http://www.gnu.org/licenses/lgpl.html
- * 
+ *
  *  - Mozilla Public License Version 1.1 or later (the "MPL")
  *    http://www.mozilla.org/MPL/MPL-1.1.html
- * 
+ *
  * == END LICENSE ==
--->
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
-<html>
+--%>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
 	<head>
 		<title>FCKeditor - JSP Sample</title>
-		<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-		<meta name="robots" content="noindex, nofollow">
+		<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
+		<meta name="robots" content="noindex, nofollow" />
 		<link href="../sample.css" rel="stylesheet" type="text/css" />
 		<script type="text/javascript">
-
-function FCKeditor_OnComplete( editorInstance )
-{
-	window.status = editorInstance.Description ;
-}
-
+			function FCKeditor_OnComplete(editorInstance) {
+				window.status = editorInstance.Description;
+			}
 		</script>
 	</head>
 	<body>
 		<h1>FCKeditor - JSP - Sample 2</h1>
-		This sample displays a normal HTML form with an FCKeditor with full features enabled.<br>
-		This sample uses the FCKeditor Taglib: this method is preferred to <a href="sample01.jsp">the API version</a><br>
+		This sample displays a normal HTML form with an FCKeditor with full 
+		features enabled.<br />
+		This sample uses the FCKeditor Taglib: this method is preferred to 
+		<a href="sample01.jsp">the API version</a><br />
 		All other sample pages will use this method.
-		<hr>
+		<hr />
 		<form action="sampleposteddata.jsp" method="get" target="_blank">
-			
 			<FCK:editor instanceName="EditorDefault">
-				<FCK:content>This is some <strong>sample text</strong>. You are using <a href="http://www.fredck.com/fckeditor/">FCKeditor</a>.</FCK:content>				
+				<FCK:content>This is some <strong>sample text</strong>. You are 
+				using <a href="http://www.fredck.com/fckeditor/">FCKeditor</a>.
+				</FCK:content>
 			</FCK:editor>
-			
 			<br />
-			<input type="submit" value="Submit">
+			<input type="submit" value="Submit" />
 		</form>
 	</body>
Index: /FCKeditor.Java/branches/2.4/src/main/webapp/jsp/sample03.jsp
===================================================================
--- /FCKeditor.Java/branches/2.4/src/main/webapp/jsp/sample03.jsp	(revision 1481)
+++ /FCKeditor.Java/branches/2.4/src/main/webapp/jsp/sample03.jsp	(revision 1482)
@@ -1,80 +1,65 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<%@ page language="java" contentType="text/html; charset=UTF-8"
+	pageEncoding="UTF-8" %>
 <%@ taglib uri="http://www.fckeditor.net/tags" prefix="FCK" %>
-<!--
+<%--
  * FCKeditor - The text editor for Internet - http://www.fckeditor.net
  * Copyright (C) 2003-2008 Frederico Caldeira Knabben
- * 
+ *
  * == BEGIN LICENSE ==
- * 
+ *
  * Licensed under the terms of any of the following licenses at your
  * choice:
- * 
+ *
  *  - GNU General Public License Version 2 or later (the "GPL")
  *    http://www.gnu.org/licenses/gpl.html
- * 
+ *
  *  - GNU Lesser General Public License Version 2.1 or later (the "LGPL")
  *    http://www.gnu.org/licenses/lgpl.html
- * 
+ *
  *  - Mozilla Public License Version 1.1 or later (the "MPL")
  *    http://www.mozilla.org/MPL/MPL-1.1.html
- * 
+ *
  * == END LICENSE ==
--->
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
-<html>
+--%>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
 	<head>
 		<title>FCKeditor - JSP Sample</title>
-		<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-		<meta name="robots" content="noindex, nofollow">
-		<link href="../sample.css" rel="stylesheet" type="text/css">
-			<script type="text/javascript">
+		<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
+		<meta name="robots" content="noindex, nofollow" />
+		<link href="../sample.css" rel="stylesheet" type="text/css" />
+		<script type="text/javascript">
+			function FCKeditor_OnComplete(editorInstance) {
+				var oCombo = document.getElementById( 'cmbLanguages' );
+				for (code in editorInstance.Language.AvailableLanguages) {
+					AddComboOption( oCombo,	editorInstance.Language.AvailableLanguages[code] + '(' + code + ')', code);
+				}
 
-function FCKeditor_OnComplete( editorInstance )
-{
-	var oCombo = document.getElementById( 'cmbLanguages' ) ;
-	for ( code in editorInstance.Language.AvailableLanguages )
-	{
-		AddComboOption( oCombo, editorInstance.Language.AvailableLanguages[code] + ' (' + code + ')', code ) ;
-	}
-	oCombo.value = editorInstance.Language.ActiveLanguage.Code ;
-}	
+				oCombo.value = editorInstance.Language.ActiveLanguage.Code;
+			}
 
-function AddComboOption(combo, optionText, optionValue)
-{
-	var oOption = document.createElement("OPTION") ;
+			function AddComboOption(combo, optionText, optionValue) {
+				var oOption = document.createElement("OPTION");
+				combo.options.add(oOption);
 
-	combo.options.add(oOption) ;
+				oOption.innerHTML = optionText;
+				oOption.value = optionValue;
+	
+				return oOption;
+			}
 
-	oOption.innerHTML = optionText ;
-	oOption.value     = optionValue ;
-	
-	return oOption ;
-}
-
-function ChangeLanguage( languageCode )
-{
-	window.location.href = window.location.pathname + "?code=" + languageCode ;
-}
-			</script>
+			function ChangeLanguage(languageCode) {
+				if (languageCode != "-1")
+					window.location.href = window.location.pathname + "?code=" + languageCode;
+			}
+		</script>
 	</head>
-<%
-String autoDetectLanguageStr;
-String defaultLanguageStr;
-
-String codeStr=request.getParameter("code");
-if(codeStr==null) {
-	autoDetectLanguageStr="true";
-	defaultLanguageStr="en";
-}
-else {
-	autoDetectLanguageStr="false";
-	defaultLanguageStr=codeStr;
-}
-
-%>	
 	<body>
 		<h1>FCKeditor - JSP - Sample 3</h1>
-		This sample shows the editor in all it's available languages.<br>
+		This sample shows the editor in all it's available languages.<br />
 		The Language dropdown is populated with JavaScript API.
-		<hr>
+		<hr />
 		<table cellpadding="0" cellspacing="0" border="0">
 			<tr>
@@ -83,18 +68,21 @@
 				</td>
 				<td>
-					<select id="cmbLanguages" onchange="ChangeLanguage(this.value);">
+					<select id="cmbLanguages" onchange="ChangeLanguage(this.value);" >
+						<option value="-1">none selected</option>
 					</select>
 				</td>
 			</tr>
 		</table>
-		<br>
+		<br />
 		<form action="sampleposteddata.jsp" method="get" target="_blank">
-			<FCK:editor id="EditorDefault"
-				autoDetectLanguage="<%=autoDetectLanguageStr%>"
-				defaultLanguage="<%=defaultLanguageStr%>">
-				This is some <strong>sample text</strong>. You are using <a href="http://www.fredck.com/fckeditor/">FCKeditor</a>.
+			<FCK:editor instanceName="EditorDefault">
+				<FCK:config param="AutoDetectLanguage" value="${empty param.code ? true : false}" />
+				<FCK:config param="DefaultLanguage" value="${empty param.code ? 'en' : param.code}"/>
+				<FCK:content>This is some <strong>sample text</strong>. You are 
+				using <a href="http://www.fredck.com/fckeditor/">FCKeditor</a>.
+				</FCK:content>
 			</FCK:editor>
-			<br>
-			<input type="submit" value="Submit">
+			<br />
+			<input type="submit" value="Submit" />
 		</form>
 	</body>
