Browser and Tasks Google Gadgets improvements and IE6/7 rendering fixes. Fix to FormData to strip path from upload filename from IE.

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@7298 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Kevin Roast
2007-11-05 16:44:13 +00:00
parent eb989afb99
commit 97239fcf17
2 changed files with 11 additions and 5 deletions

View File

@@ -43,6 +43,7 @@ import org.apache.commons.fileupload.FileItemFactory;
import org.apache.commons.fileupload.FileUploadException;
import org.apache.commons.fileupload.disk.DiskFileItemFactory;
import org.apache.commons.fileupload.servlet.ServletFileUpload;
import org.apache.commons.io.FilenameUtils;
import org.mozilla.javascript.Context;
import org.mozilla.javascript.Scriptable;
@@ -320,14 +321,13 @@ public class FormData implements Serializable, Scopeable
*/
public String getFilename()
{
return file.getName();
// workaround a bug in IE where the full path is returned
return FilenameUtils.getName(file.getName());
}
public String jsGet_filename()
{
return getFilename();
}
}
}

View File

@@ -27,7 +27,7 @@ div.toolbar
div.titlebar
{
font-weight: bold;
padding: 2 0 2 8;
padding: 2px 0px 2px 8px;
background-color: #DCE4EB;
border-bottom: 1px solid #CCD4DB;
}
@@ -60,6 +60,12 @@ a:hover
color: #168ECE;
}
form
{
padding: 0px;
margin: 0px;
}
input
{
font-family: Trebuchet MS, Arial, sans-serif;
@@ -69,7 +75,7 @@ input
color: #515D6B;
background-color: #F8FCFD;
border: 1px solid #CCD4DB;
width: 100%;
width: 97%;
}
input.formItemError