Index: FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/connector/Connector.java
===================================================================
--- FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/connector/Connector.java	(revision 2589)
+++ FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/connector/Connector.java	(revision 2590)
@@ -110,5 +110,7 @@
 	/**
 	 * Uploads a new file into the abstract path <code>/[type-folder]/[currentFolder]</code>. If there is 
-	 * already a file with the same name, the new one has to renamed.
+	 * already a file with the same name, the new one has to be renamed.<br/>
+	 * FileUpload and QuickUpload will be handled the same way since QuickUpload
+	 * is just a specialization of FileUpload.
 	 * 
 	 * @param type
@@ -122,14 +124,4 @@
 	public String fileUpload(final ResourceType type, final String currentFolder, final String fileName, final InputStream inputStream)
 		throws InvalidCurrentFolderException, SecurityIssueException;
-	
-	/**
-	 * Uploads a new file into the top of <code>userFiles</code>. If there is 
-	 * already a file with the same name, the new one has to renamed.
-	 * 
-	 * @param fileName
-	 * @param inputStream Content of the file.
-	 * @return
-	 * @throws SecurityIssueException
-	 */
-	public String quickUpload(final String fileName, final InputStream inputStream) throws SecurityIssueException;
+
 }
Index: FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/connector/ConnectorServlet.java
===================================================================
--- FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/connector/ConnectorServlet.java	(revision 2589)
+++ FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/connector/ConnectorServlet.java	(revision 2590)
@@ -75,5 +75,6 @@
 			dispatcher.doGet(request, response);
 		} catch (Exception e) {
-			// if an exception wasn't catched by the Dispatcher, it is a fatal one and has to re-thrown.
+			// if an exception wasn't catched by the Dispatcher, it is a fatal
+			// one and has to re-thrown.
 			if (e instanceof IOException)
 				throw (IOException) e;
@@ -95,7 +96,8 @@
 			dispatcher.doPost(request, response);
 		} catch (Exception e) {
-			// if an exception wasn't catched by the Dispatcher, it is a fatal one and has to re-thrown.
+			// if an exception wasn't catched by the Dispatcher, it is a fatal
+			// one and has to re-thrown.
 			if (e instanceof IOException)
-				throw new IOException(e.getLocalizedMessage());
+				throw (IOException) e;
 			else
 				throw new ServletException(e);
Index: FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/connector/Dispatcher.java
===================================================================
--- FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/connector/Dispatcher.java	(revision 2589)
+++ FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/connector/Dispatcher.java	(revision 2590)
@@ -120,8 +120,8 @@
 			if ((command.equals(CommandHandler.GET_FOLDERS) || command
 					.equals(CommandHandler.GET_FOLDERS_AND_FILES))
-					&& !RequestCycleHandler.isEnabledForFileBrowsing())
+					&& !RequestCycleHandler.isEnabledForFileBrowsing(request))
 				getResponse = GetResponse.getErrorFileBrowsingDisabled();
 			else if (command.equals(CommandHandler.CREATE_FOLDER)
-					&& !RequestCycleHandler.isEnabledForFolderCreation())
+					&& !RequestCycleHandler.isEnabledForFolderCreation(request))
 				getResponse = GetResponse.getErrorFolderCreationDisabled();
 			
@@ -208,5 +208,6 @@
 	 * @throws IOException 
 	 */
-	public void doPost(final HttpServletRequest request, final HttpServletResponse response) throws IOException {
+	public void doPost(final HttpServletRequest request,
+			final HttpServletResponse response) throws IOException {
 		logger.debug("Entering Dispatcher#doPost");
 		Context context = ThreadLocalData.getContext();
@@ -219,18 +220,13 @@
 		context.logBaseParameters();
 		
-		// if this is a QuickUpload request, 'commandStr' and 'currentFolderStr'
-		// are empty
-		boolean isQuickUpload = context.checkQuickUpload();
-		
 		UploadResponse uploadResponse;
 		// check permissions for user actions
-		if (!RequestCycleHandler.isEnabledForFileUpload())
+		if (!RequestCycleHandler.isEnabledForFileUpload(request))
 			uploadResponse = UploadResponse.getErrorFileUploadDisabled();
-
 		// check parameters  
 		// TODO should we move the parameter check to Context -> throws an exception?
 		else if (!CommandHandler.isValidForPost(context.getCommandStr()))
 			uploadResponse = UploadResponse.getErrorInvalidCommand();
-		else if (!isQuickUpload && !ResourceType.isValid(context.getTypeStr()))
+		else if (!ResourceType.isValid(context.getTypeStr()))
 			uploadResponse = UploadResponse.getErrorInvalidType();
 		else if (!UtilsFile.isValidPath(context.getCurrentFolderStr()))
@@ -243,27 +239,43 @@
 			ServletFileUpload upload = new ServletFileUpload(factory);
 			try {
-				@SuppressWarnings("unchecked") List<FileItem> items = upload.parseRequest(request);
+				@SuppressWarnings("unchecked")
+				List<FileItem> items = upload.parseRequest(request);
 				// We upload just one file at the same time
 				FileItem uplFile = items.get(0);
-				// check the extension (can't be done if QuickUpload)
-				if (!isQuickUpload && !ExtensionsHandler.isAllowed(type, FilenameUtils.getExtension(uplFile.getName())))
+				// Some browsers transfer the entire source path not just the
+				// filename
+				String fileName = FilenameUtils.getName(uplFile.getName());
+				logger.debug("Parameter NewFile: {}", fileName);
+				// check the extension
+				if (!ExtensionsHandler.isAllowed(type, FilenameUtils
+						.getExtension(fileName)))
 					uploadResponse = UploadResponse.getErrorInvalidExtension();
 				// Secure image check (can't be done if QuickUpload)
-				else if (!isQuickUpload && type.equals(ResourceType.IMAGE) && ConnectorHandler.isSecureImageUploads() && !UtilsFile.isImage(uplFile.getInputStream())) {
+				else if (type.equals(ResourceType.IMAGE)
+						&& ConnectorHandler.isSecureImageUploads()
+						&& !UtilsFile.isImage(uplFile.getInputStream())) {
 					uploadResponse = UploadResponse.getErrorInvalidExtension();
 				} else {
-					String fileName = FilenameUtils.getName(UtilsFile.sanitizeFileName(uplFile.getName()));
-					String newFileName;
-					if (isQuickUpload) {
-						newFileName = connector.quickUpload(fileName, uplFile.getInputStream());
-					} else {
-						newFileName = connector.fileUpload(type, context.getCurrentFolderStr(), fileName, uplFile.getInputStream());
+					String sanitizedFileName = UtilsFile
+							.sanitizeFileName(fileName);
+					logger.debug("Parameter NewFile (sanitized): {}",
+							sanitizedFileName);
+					String newFileName = connector.fileUpload(type, context
+							.getCurrentFolderStr(), sanitizedFileName, uplFile
+							.getInputStream());
+					// TODO I don't like this either
+					String responseUrl = context.buildUrl(ConnectorHandler
+							.getUserFilesPath());
+					if (sanitizedFileName.equals(newFileName))
+						uploadResponse = new UploadResponse(
+								UploadResponse.SC_OK, responseUrl);
+					else {
+						uploadResponse = new UploadResponse(
+								UploadResponse.SC_RENAMED, responseUrl,
+								newFileName);
+						logger.debug("Parameter NewFile (renamed): {}",
+								newFileName);
+						
 					}
-					// TODO I don't like this either
-					String responseUrl = context.buildUrl(ConnectorHandler.getUserFilesPath());
-					if (fileName.equals(newFileName))
-						uploadResponse = new UploadResponse(UploadResponse.SC_OK, responseUrl);
-					else
-						uploadResponse =  new UploadResponse(UploadResponse.SC_RENAMED, responseUrl, newFileName); 
 				}
 				uplFile.delete();
Index: FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/handlers/RequestCycleHandler.java
===================================================================
--- FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/handlers/RequestCycleHandler.java	(revision 2589)
+++ FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/handlers/RequestCycleHandler.java	(revision 2590)
@@ -21,4 +21,6 @@
 package net.fckeditor.handlers;
 
+
+import javax.servlet.http.HttpServletRequest;
 
 import net.fckeditor.requestcycle.UserAction;
@@ -82,6 +84,6 @@
 	 *         or false if {@link UserAction} isn't set.
 	 */
-	public static boolean isEnabledForFileBrowsing() {
-		return (userAction != null && userAction.isEnabledForFileBrowsing());
+	public static boolean isEnabledForFileBrowsing(final HttpServletRequest request) {
+		return (userAction != null && userAction.isEnabledForFileBrowsing(request));
 	}
 
@@ -93,6 +95,6 @@
 	 *         false if {@link UserAction} isn't set.
 	 */
-	public static boolean isEnabledForFileUpload() {
-		return (userAction != null && userAction.isEnabledForFileUpload());
+	public static boolean isEnabledForFileUpload(final HttpServletRequest request) {
+		return (userAction != null && userAction.isEnabledForFileUpload(request));
 	}
 
@@ -104,6 +106,6 @@
 	 *         false if {@link UserAction} isn't set.
 	 */
-	public static boolean isEnabledForFolderCreation() {
-		return (userAction != null && userAction.isEnabledForFolderCreation());
+	public static boolean isEnabledForFolderCreation(final HttpServletRequest request) {
+		return (userAction != null && userAction.isEnabledForFolderCreation(request));
 	}
 
@@ -117,6 +119,16 @@
 	 *         <code>null</code>.
 	 */
-	public static String getUserFilesPath() {
-		return (userPathBuilder != null) ? userPathBuilder.getUserFilesPath() : null;
+	public static String getUserFilesPath(final HttpServletRequest request) {
+		return (userPathBuilder != null) ? userPathBuilder.getUserFilesPath(request) : null;
+	}
+	
+	
+	/**
+	 * 
+	 * @param request
+	 * @return
+	 */
+	public static String getUserFilesAbsolutePath(final HttpServletRequest request) {
+		return (userPathBuilder != null) ? userPathBuilder.getUserFilesAbsolutePath(request) : null;
 	}
 }
Index: FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/requestcycle/Context.java
===================================================================
--- FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/requestcycle/Context.java	(revision 2589)
+++ FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/requestcycle/Context.java	(revision 2590)
@@ -23,6 +23,6 @@
 import javax.servlet.http.HttpServletRequest;
 
+import net.fckeditor.connector.Dispatcher;
 import net.fckeditor.handlers.CommandHandler;
-import net.fckeditor.handlers.ConnectorHandler;
 import net.fckeditor.handlers.ResourceType;
 import net.fckeditor.tool.Utils;
@@ -37,5 +37,6 @@
  */
 public class Context {
-	private static final Logger logger = LoggerFactory.getLogger(Context.class);
+	// This is just a helper class which has no relevance for the logger
+	private static final Logger logger = LoggerFactory.getLogger(Dispatcher.class);
 	
 	private String typeStr;
@@ -48,16 +49,14 @@
 		currentFolderStr = request.getParameter("CurrentFolder");
 		
+		// if this is a QuickUpload request, 'commandStr' and 'currentFolderStr'
+		// are empty
+		if (Utils.isEmpty(commandStr) && Utils.isEmpty(currentFolderStr)) {
+			commandStr = "QuickUpload";
+			currentFolderStr = "/";
+		}
+		
 		// checks to meet specs in http://docs.fckeditor.net/FCKeditor_2.x/Developers_Guide/Server_Side_Integration#File_Browser_Requests
 		if (currentFolderStr != null && !currentFolderStr.startsWith("/"))
 			currentFolderStr = "/".concat(currentFolderStr);
-	}
-	
-	public boolean checkQuickUpload() {
-		if (Utils.isEmpty(commandStr) && Utils.isEmpty(currentFolderStr)) {
-			commandStr = "QuickUpload";
-			currentFolderStr = "/";
-			return true;
-		}
-		return false;
 	}
 	
@@ -113,5 +112,5 @@
 	public String buildUrl(final String baseDir) {
     	StringBuffer sb = new StringBuffer();
-    	HttpServletRequest request = ThreadLocalData.getServletRequest();
+    	HttpServletRequest request = ThreadLocalData.getRequest();
     	    	
     	sb.append(baseDir);
Index: FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/requestcycle/ThreadLocalData.java
===================================================================
--- FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/requestcycle/ThreadLocalData.java	(revision 2589)
+++ FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/requestcycle/ThreadLocalData.java	(revision 2590)
@@ -29,20 +29,20 @@
  */
 public class ThreadLocalData {
-	private static ThreadLocal<HttpServletRequest> servletRequest = null;
+	private static ThreadLocal<HttpServletRequest> request = null;
 	private static ThreadLocal<Context> context = null;
 	
-	public static void beginRequest(final HttpServletRequest servletRequest) {
-		if (servletRequest == null)
+	public static void beginRequest(final HttpServletRequest request) {
+		if (request == null)
 			throw new IllegalArgumentException();
-		if (ThreadLocalData.servletRequest == null)
-			ThreadLocalData.servletRequest = new ThreadLocal<HttpServletRequest>();
-		ThreadLocalData.servletRequest.set(servletRequest);
+		if (ThreadLocalData.request == null)
+			ThreadLocalData.request = new ThreadLocal<HttpServletRequest>();
+		ThreadLocalData.request.set(request);
 		if (ThreadLocalData.context == null)
 			ThreadLocalData.context = new ThreadLocal<Context>();
-		ThreadLocalData.context.set(new Context(servletRequest));
+		ThreadLocalData.context.set(new Context(request));
 	}
 	
-	public static HttpServletRequest getServletRequest() {
-		return (servletRequest == null) ? null : servletRequest.get();
+	public static HttpServletRequest getRequest() {
+		return (request == null) ? null : request.get();
 	}
 	
@@ -53,8 +53,9 @@
 	/**
 	 * Clear the ThreadLocals.<br>
-	 * <b>Important: To prevent memory leaks we have to make sure that this method is calling at the end of each request cycle!!!</b>
+	 * <strong>Important: To prevent memory leaks we have to make sure that this
+	 * method is calling at the end of each request cycle!!!</strong>
 	 */
 	public static void endRequest() {
-		servletRequest = null;
+		request = null;
 		context = null;
 	}
Index: FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/requestcycle/UserPathBuilder.java
===================================================================
--- FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/requestcycle/UserPathBuilder.java	(revision 2589)
+++ FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/requestcycle/UserPathBuilder.java	(revision 2590)
@@ -45,10 +45,10 @@
 	 * </ul>
 	 * <strong>If your implementation needs {@link HttpServletRequest} e.g. to get a
-	 * session variable, you can get it by calling {@link ThreadLocalData#getServletRequest()}. </strong>
+	 * session variable, you can get it by calling {@link ThreadLocalData#getRequest()}. </strong>
 	 * 
 	 * @param request
 	 * @return <code>UserFilesPath</code> for the current user.
 	 */
-	public String getUserFilesPath();
+	public String getUserFilesPath(final HttpServletRequest request);
 	
 	/**
@@ -58,4 +58,4 @@
 	 * @return
 	 */
-	public String getUserFilesAbsolutePath();
+	public String getUserFilesAbsolutePath(final HttpServletRequest request);
 }
Index: FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/requestcycle/impl/DisabledUserAction.java
===================================================================
--- FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/requestcycle/impl/DisabledUserAction.java	(revision 2589)
+++ FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/requestcycle/impl/DisabledUserAction.java	(revision 2590)
@@ -22,4 +22,6 @@
 
 
+import javax.servlet.http.HttpServletRequest;
+
 import net.fckeditor.requestcycle.UserAction;
 
@@ -36,5 +38,5 @@
 	 * @see net.fckeditor.requestcycle.UserAction#isEnabledForFileBrowsing()
 	 */
-	public boolean isEnabledForFileBrowsing() {
+	public boolean isEnabledForFileBrowsing(final HttpServletRequest request) {
 		return false;
 	}
@@ -44,5 +46,5 @@
 	 * @see net.fckeditor.requestcycle.UserAction#isEnabledForFileUpload()
 	 */
-	public boolean isEnabledForFileUpload() {
+	public boolean isEnabledForFileUpload(final HttpServletRequest request) {
 		return false;
 	}
@@ -52,5 +54,5 @@
 	 * @see net.fckeditor.requestcycle.UserAction#isEnabledForFolderCreation()
 	 */
-	public boolean isEnabledForFolderCreation() {
+	public boolean isEnabledForFolderCreation(final HttpServletRequest request) {
 		return false;
 	}
Index: FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/requestcycle/impl/EnabledUserAction.java
===================================================================
--- FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/requestcycle/impl/EnabledUserAction.java	(revision 2589)
+++ FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/requestcycle/impl/EnabledUserAction.java	(revision 2590)
@@ -22,4 +22,6 @@
 
 
+import javax.servlet.http.HttpServletRequest;
+
 import net.fckeditor.requestcycle.UserAction;
 
@@ -36,5 +38,5 @@
 	 * @see net.fckeditor.requestcycle.UserAction#isEnabledForFileBrowsing()
 	 */
-	public boolean isEnabledForFileBrowsing() {
+	public boolean isEnabledForFileBrowsing(final HttpServletRequest request) {
 		return true;
 	}
@@ -44,5 +46,5 @@
 	 * @see net.fckeditor.requestcycle.UserAction#isEnabledForFileUpload()
 	 */
-	public boolean isEnabledForFileUpload() {
+	public boolean isEnabledForFileUpload(final HttpServletRequest request) {
 		return true;
 	}
@@ -52,5 +54,5 @@
 	 * @see net.fckeditor.requestcycle.UserAction#isEnabledForFolderCreation()
 	 */
-	public boolean isEnabledForFolderCreation() {
+	public boolean isEnabledForFolderCreation(final HttpServletRequest request) {
 		return true;
 	}
Index: FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/requestcycle/impl/UserActionImpl.java
===================================================================
--- FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/requestcycle/impl/UserActionImpl.java	(revision 2589)
+++ FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/requestcycle/impl/UserActionImpl.java	(revision 2590)
@@ -22,4 +22,6 @@
 
 
+import javax.servlet.http.HttpServletRequest;
+
 import net.fckeditor.requestcycle.UserAction;
 
@@ -37,5 +39,5 @@
 	 * @see net.fckeditor.requestcycle.UserAction#isEnabledForFileBrowsing(javax.servlet.http.HttpServletRequest)
 	 */
-	public boolean isEnabledForFileBrowsing() {
+	public boolean isEnabledForFileBrowsing(final HttpServletRequest request) {
 		return true;
 	}
@@ -44,5 +46,5 @@
 	 * @see net.fckeditor.requestcycle.UserAction#isEnabledForFileUpload(javax.servlet.http.HttpServletRequest)
 	 */
-	public boolean isEnabledForFileUpload() {
+	public boolean isEnabledForFileUpload(final HttpServletRequest request) {
 		return true;
 	}
@@ -52,5 +54,5 @@
 	 * @see net.fckeditor.requestcycle.UserAction#isEnabledForFolderCreation(javax.servlet.http.HttpServletRequest)
 	 */
-	public boolean isEnabledForFolderCreation() {
+	public boolean isEnabledForFolderCreation(final HttpServletRequest request) {
 		return true;
 	}
Index: FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/response/GetResponse.java
===================================================================
--- FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/response/GetResponse.java	(revision 2589)
+++ FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/response/GetResponse.java	(revision 2590)
@@ -248,15 +248,15 @@
 	
 	public static GetResponse getErrorInvalidCommand() {
-		LocalizedPropertiesLoader lpl = LocalizedPropertiesLoader.getInstance(ThreadLocalData.getServletRequest());
+		LocalizedPropertiesLoader lpl = LocalizedPropertiesLoader.getInstance(ThreadLocalData.getRequest());
 		return new GetResponse(EN_ERROR, lpl.getInvalidCommand());
 	}
 	
 	public static GetResponse getErrorInvalidType() {
-		LocalizedPropertiesLoader lpl = LocalizedPropertiesLoader.getInstance(ThreadLocalData.getServletRequest());
+		LocalizedPropertiesLoader lpl = LocalizedPropertiesLoader.getInstance(ThreadLocalData.getRequest());
 		return new GetResponse(EN_ERROR, lpl.getInvalidType());
 	}
 	
 	public static GetResponse getErrorInvalidCurrentFolder() {
-		LocalizedPropertiesLoader lpl = LocalizedPropertiesLoader.getInstance(ThreadLocalData.getServletRequest());
+		LocalizedPropertiesLoader lpl = LocalizedPropertiesLoader.getInstance(ThreadLocalData.getRequest());
 		return new GetResponse(EN_ERROR, lpl.getInvalidCurrentFolder());
 	}
@@ -271,10 +271,10 @@
 	
 	public static GetResponse getErrorFileBrowsingDisabled() {
-		LocalizedPropertiesLoader lpl = LocalizedPropertiesLoader.getInstance(ThreadLocalData.getServletRequest());
+		LocalizedPropertiesLoader lpl = LocalizedPropertiesLoader.getInstance(ThreadLocalData.getRequest());
 		return new GetResponse(EN_ERROR, lpl.getFileBrowsingDisabled());
 	}
 
 	public static GetResponse getErrorFolderCreationDisabled() {
-		LocalizedPropertiesLoader lpl = LocalizedPropertiesLoader.getInstance(ThreadLocalData.getServletRequest());
+		LocalizedPropertiesLoader lpl = LocalizedPropertiesLoader.getInstance(ThreadLocalData.getRequest());
 		return new GetResponse(EN_ERROR, lpl.getFolderCreationDisabled());
 	}
Index: FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/response/UploadResponse.java
===================================================================
--- FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/response/UploadResponse.java	(revision 2589)
+++ FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/response/UploadResponse.java	(revision 2590)
@@ -135,20 +135,20 @@
 	
 	public static UploadResponse getErrorInvalidCommand() {
-		LocalizedPropertiesLoader lpl = LocalizedPropertiesLoader.getInstance(ThreadLocalData.getServletRequest());
+		LocalizedPropertiesLoader lpl = LocalizedPropertiesLoader.getInstance(ThreadLocalData.getRequest());
 		return new UploadResponse(SC_ERROR, null, null, lpl.getInvalidCommand());
 	}
 	
 	public static UploadResponse getErrorInvalidType() {
-		LocalizedPropertiesLoader lpl = LocalizedPropertiesLoader.getInstance(ThreadLocalData.getServletRequest());
+		LocalizedPropertiesLoader lpl = LocalizedPropertiesLoader.getInstance(ThreadLocalData.getRequest());
 		return new UploadResponse(SC_ERROR, null, null, lpl.getInvalidType());
 	}
 	
 	public static UploadResponse getErrorInvalidCurrentFolder() {
-		LocalizedPropertiesLoader lpl = LocalizedPropertiesLoader.getInstance(ThreadLocalData.getServletRequest());
+		LocalizedPropertiesLoader lpl = LocalizedPropertiesLoader.getInstance(ThreadLocalData.getRequest());
 		return new UploadResponse(SC_ERROR, null, null, lpl.getInvalidCurrentFolder());
 	}
 
 	public static UploadResponse getErrorFileUploadDisabled() {
-		LocalizedPropertiesLoader lpl = LocalizedPropertiesLoader.getInstance(ThreadLocalData.getServletRequest());
+		LocalizedPropertiesLoader lpl = LocalizedPropertiesLoader.getInstance(ThreadLocalData.getRequest());
 		return new UploadResponse(SC_ERROR, null, null, lpl.getFileUploadDisabled());
 	}
Index: FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/tags/CheckTag.java
===================================================================
--- FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/tags/CheckTag.java	(revision 2589)
+++ FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/tags/CheckTag.java	(revision 2590)
@@ -82,5 +82,5 @@
 
 		if (command.equals(FILE_UPLOAD)) {
-			if (RequestCycleHandler.isEnabledForFileUpload())
+			if (RequestCycleHandler.isEnabledForFileUpload(request))
 				response = lpl.getFileUploadEnabled();
 			else
@@ -89,5 +89,5 @@
 
 		if (command.equals(FILE_BROWSING)) {
-			if (RequestCycleHandler.isEnabledForFileBrowsing())
+			if (RequestCycleHandler.isEnabledForFileBrowsing(request))
 				response = lpl.getFileBrowsingEnabled();
 			else
Index: FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/tool/UtilsFile.java
===================================================================
--- FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/tool/UtilsFile.java	(revision 2589)
+++ FCKeditor.Java/trunk/java-core/src/main/java/net/fckeditor/tool/UtilsFile.java	(revision 2590)
@@ -156,6 +156,5 @@
 		String baseName = FilenameUtils.getBaseName(tmpFile.getName());
 		do {
-			tmpFile = new File(dir, baseName + "(".concat(String.valueOf(count)).concat(").").concat(extension));
-			count++;
+			tmpFile = new File(dir, baseName + "(" + count++ + ")." + extension);
 		} while (tmpFile.exists());
 		return tmpFile;
