www.element4solution.com

e4s.servlet
Class E4MultipartRequest

java.lang.Object
  extended by e4s.util.E4Object
      extended by e4s.servlet.E4MultipartRequest

public class E4MultipartRequest
extends E4Object

A Multipart form data parser. Parses an input stream and writes out any files found, making available a hashtable of other url parameters. As of version 1.17 the files can be saved to memory, and optionally written to a database, etc.

Copyright (c)2001-2003 Jason Pell.

 
 This library is free software; you can redistribute it and/or modify it under
 the terms of the GNU Lesser General Public License as published by the Free
 Software Foundation; either version 2.1 of the License, or (at your option)
 any later version. 
This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
Email: jasonpell@hotmail.com Url: http://www.geocities.com/jasonpell


Nested Class Summary
 class E4MultipartRequest.EmptyInputStream
          A Multipart form data parser.
 
Field Summary
static int ABORT_IF_MAX_BYES_EXCEEDED
          Mode
static int CONTENT_TYPE
           
static int CONTENTS
           
static java.lang.String DEF_ENCODING
           
static int FILENAME
          Define the array indexes for the htFiles Object array.
static int IGNORE_FILES_IF_MAX_BYES_EXCEEDED
           
static int MAX_READ_BYTES
          Prevent a denial of service by defining this, will never read more data.
static int RAW_FILENAME
           
static int READ_LINE_BLOCK
          Defines the number of bytes to read per readLine call. 128K
static int SIZE
           
static int TMP_FILENAME
           
 
Fields inherited from class e4s.util.E4Object
CRLF, E4S_CORE_SYSTEM_LANGUAGE, NBSP, NULLSTR, URL_ENCODING_CHARSET
 
Constructor Summary
E4MultipartRequest(java.io.PrintWriter debug, java.lang.String strContentTypeText, int intContentLength, java.io.InputStream in, int intMaxReadBytes)
          Deprecated. Replaced by E4MultipartRequest(PrintWriter, String, int, InputStream, int, boolean, String)
E4MultipartRequest(java.io.PrintWriter debug, java.lang.String strContentTypeText, int intContentLength, java.io.InputStream in, int intMaxReadBytes, int maxBytesExceededMode, java.lang.String encoding)
          Memory Constructor
E4MultipartRequest(java.io.PrintWriter debug, java.lang.String strContentTypeText, int intContentLength, java.io.InputStream in, int intMaxReadBytes, java.lang.String encoding)
          Memory Constructor
E4MultipartRequest(java.io.PrintWriter debug, java.lang.String strContentTypeText, int intContentLength, java.io.InputStream in, java.lang.String strSaveDirectory)
          Deprecated. Replaced by E4MultipartRequest(PrintWriter, String, int, InputStream, String, int, boolean, String)
E4MultipartRequest(java.io.PrintWriter debug, java.lang.String strContentTypeText, int intContentLength, java.io.InputStream in, java.lang.String strSaveDirectory, int intMaxReadBytes)
          Deprecated. Replaced by E4MultipartRequest(PrintWriter, String, int, InputStream, String, int, boolean, String)
E4MultipartRequest(java.io.PrintWriter debug, java.lang.String strContentTypeText, int intContentLength, java.io.InputStream in, java.lang.String strSaveDirectory, int intMaxReadBytes, int maxBytesExceededMode, java.lang.String encoding)
          Standard Constructor
E4MultipartRequest(java.io.PrintWriter debug, java.lang.String strContentTypeText, int intContentLength, java.io.InputStream in, java.lang.String strSaveDirectory, int intMaxReadBytes, java.lang.String encoding)
          Standard Constructor
E4MultipartRequest(java.lang.String strContentTypeText, int intContentLength, java.io.InputStream in, java.lang.String strSaveDirectory)
          Deprecated. Replaced by E4MultipartRequest(PrintWriter, String, int, InputStream, String, int, boolean, String)
E4MultipartRequest(java.lang.String strContentTypeText, int intContentLength, java.io.InputStream in, java.lang.String strSaveDirectory, int intMaxReadBytes)
          Deprecated. Replaced by E4MultipartRequest(PrintWriter, String, int, InputStream, String, int, boolean, String)
 
Method Summary
static java.lang.String _getSVNVersionString()
          Get version info string from subversion.
 java.lang.String getBaseFilename(java.lang.String strName)
          Get the uploaded file basename.
 java.lang.String getContentType(java.lang.String strName)
          Returns the Content-Type of a file.
 java.lang.String getEncoding()
          Returns the current encoding method.
 java.io.File getFile(java.lang.String strName)
          Returns a File reference to the uploaded file.
 java.io.InputStream getFileContents(java.lang.String strName)
          If files were uploaded into memory, this method will retrieve the contents of the file as a InputStream.
 java.lang.Object getFileParameter(java.lang.String strName, int type)
          Access an attribute of a file upload parameter record.
 java.util.Enumeration getFileParameterNames()
          This enumeration will return all INPUT TYPE=FILE parameter NAMES as encountered during the upload.
 long getFileSize(java.lang.String strName)
          Returns the File Size of a uploaded file.
 java.lang.String getHtmlTable()
          For debugging.
 java.util.Enumeration getNames()
          An enumeration of all URL Parameters for the current HTTP Request.
 java.lang.String getRawFilename(java.lang.String strName)
          Get the uploaded file basename.
 java.lang.String getURLParameter(java.lang.String strName)
          Return the value of the strName URLParameter.
 java.util.Enumeration getURLParameters(java.lang.String strName)
          Return an enumeration of all values for the strName parameter.
 boolean isMaxBytesExceeded()
          If this class was constructed with a maxBytesExceeded mode of E4MultipartRequest.IGNORE_FILES_IF_MAX_BYES_EXCEEDED, this method will indicate whether the process is ignoring file content because the content-length was exceeded.
 void setEncoding(java.lang.String enc)
          Sets up the encoding for this instance of multipartrequest.
 
Methods inherited from class e4s.util.E4Object
Calendar, CName, CName, E4LabelApp, E4LabelApp, E4LabelApp, E4LabelApp, E4LabelApp, E4LabelApp, E4LabelNone, E4LabelNone, E4LabelNone, E4LabelNone, E4LabelSys, E4LabelSys, e4sCopyright, e4sVersion, encode, encode, encode, encodeHtml, encodeHtml, encodeHtml, encodeURL, encodeURL, encodeURL, finalize, getLINE, getTRACE, getTRACE, getTRACE, getTRACE, getTRACE, getTRACE, getTraceMemory, HtmlEncode, HtmlEncode, HtmlEncode, isdecimal, isdigit, isnotok, isnotok, isnumeric, isok, isok, isok, isok, lastCallingFunction, lastCallingFunction, lastCallingFunction, lastCallingFunction, lastCallingStack, mkdirs, null2nbsp, null2nbsp, null2nbsp, ok, ok, ok, ok, outPrintln, setLogFile4Trace, setTraceMemory, STACKTRACE, toDebug, toDouble, toFloat, toFloat, toString, TRACE_CALLS, TRACE, TRACE, TRACE, TRACE, TRACE, TRACE, TRACE, TRACE, TRACE, TRACE, TRACE, TRACE, wait
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

DEF_ENCODING

public static final java.lang.String DEF_ENCODING
See Also:
Constant Field Values

MAX_READ_BYTES

public static final int MAX_READ_BYTES
Prevent a denial of service by defining this, will never read more data. If Content-Length is specified to be more than this, will throw an exception. This limits the maximum number of bytes to the value of an int, which is 4 MB.

See Also:
Constant Field Values

READ_LINE_BLOCK

public static final int READ_LINE_BLOCK
Defines the number of bytes to read per readLine call. 128K

See Also:
Constant Field Values

FILENAME

public static final int FILENAME
Define the array indexes for the htFiles Object array.

See Also:
Constant Field Values

CONTENT_TYPE

public static final int CONTENT_TYPE
See Also:
Constant Field Values

SIZE

public static final int SIZE
See Also:
Constant Field Values

CONTENTS

public static final int CONTENTS
See Also:
Constant Field Values

TMP_FILENAME

public static final int TMP_FILENAME
See Also:
Constant Field Values

RAW_FILENAME

public static final int RAW_FILENAME
See Also:
Constant Field Values

ABORT_IF_MAX_BYES_EXCEEDED

public static final int ABORT_IF_MAX_BYES_EXCEEDED
Mode

See Also:
Constant Field Values

IGNORE_FILES_IF_MAX_BYES_EXCEEDED

public static final int IGNORE_FILES_IF_MAX_BYES_EXCEEDED
See Also:
Constant Field Values
Constructor Detail

E4MultipartRequest

public E4MultipartRequest(java.lang.String strContentTypeText,
                          int intContentLength,
                          java.io.InputStream in,
                          java.lang.String strSaveDirectory)
                   throws java.lang.IllegalArgumentException,
                          java.io.IOException
Deprecated. Replaced by E4MultipartRequest(PrintWriter, String, int, InputStream, String, int, boolean, String)

Standard Constructor

Parameters:
strContentTypeText - The "Content-Type" HTTP header value.
intContentLength - The "Content-Length" HTTP header value.
in - The InputStream to read and parse.
strSaveDirectory - The temporary directory to save the file from where they can then be moved to wherever by the
Throws:
java.lang.IllegalArgumentException - If the strContentTypeText does not contain a Content-Type of "multipart/form-data" or the boundary is not found.
java.io.IOException - If the intContentLength is higher than MAX_READ_BYTES or strSaveDirectory is invalid or cannot be written to.
See Also:
MAX_READ_BYTES

E4MultipartRequest

public E4MultipartRequest(java.lang.String strContentTypeText,
                          int intContentLength,
                          java.io.InputStream in,
                          java.lang.String strSaveDirectory,
                          int intMaxReadBytes)
                   throws java.lang.IllegalArgumentException,
                          java.io.IOException
Deprecated. Replaced by E4MultipartRequest(PrintWriter, String, int, InputStream, String, int, boolean, String)

Standard Constructor

Parameters:
strContentTypeText - The "Content-Type" HTTP header value.
intContentLength - The "Content-Length" HTTP header value.
in - The InputStream to read and parse.
strSaveDirectory - The temporary directory to save the file from where they can then be moved to wherever by the calling process. If you specify null for this parameter, then any files uploaded will be silently ignored.
intMaxReadBytes - Overrides the MAX_BYTES_READ value, to allow arbitrarily long files.
Throws:
java.lang.IllegalArgumentException - If the strContentTypeText does not contain a Content-Type of "multipart/form-data" or the boundary is not found.
java.io.IOException - If the intContentLength is higher than MAX_READ_BYTES or strSaveDirectory is invalid or cannot be written to.
See Also:
MAX_READ_BYTES

E4MultipartRequest

public E4MultipartRequest(java.io.PrintWriter debug,
                          java.lang.String strContentTypeText,
                          int intContentLength,
                          java.io.InputStream in,
                          java.lang.String strSaveDirectory)
                   throws java.lang.IllegalArgumentException,
                          java.io.IOException
Deprecated. Replaced by E4MultipartRequest(PrintWriter, String, int, InputStream, String, int, boolean, String)

Standard Constructor

Parameters:
debug - A PrintWriter that can be used for debugging.
strContentTypeText - The "Content-Type" HTTP header value.
intContentLength - The "Content-Length" HTTP header value.
in - The InputStream to read and parse.
strSaveDirectory - The temporary directory to save the file from where they can then be moved to wherever by the calling process. If you specify null for this parameter, then any files uploaded will be silently ignored.
Throws:
java.lang.IllegalArgumentException - If the strContentTypeText does not contain a Content-Type of "multipart/form-data" or the boundary is not found.
java.io.IOException - If the intContentLength is higher than MAX_READ_BYTES or strSaveDirectory is invalid or cannot be written to.
See Also:
MAX_READ_BYTES

E4MultipartRequest

public E4MultipartRequest(java.io.PrintWriter debug,
                          java.lang.String strContentTypeText,
                          int intContentLength,
                          java.io.InputStream in,
                          int intMaxReadBytes)
                   throws java.lang.IllegalArgumentException,
                          java.io.IOException
Deprecated. Replaced by E4MultipartRequest(PrintWriter, String, int, InputStream, int, boolean, String)

Memory Constructor

Parameters:
debug - A PrintWriter that can be used for debugging.
strContentTypeText - The "Content-Type" HTTP header value.
intContentLength - The "Content-Length" HTTP header value.
in - The InputStream to read and parse.
intMaxReadBytes - Overrides the MAX_BYTES_READ value, to allow arbitrarily long files.
Throws:
java.lang.IllegalArgumentException - If the strContentTypeText does not contain a Content-Type of "multipart/form-data" or the boundary is not found.
java.io.IOException - If the intContentLength is higher than MAX_READ_BYTES or strSaveDirectory is invalid or cannot be written to.
See Also:
MAX_READ_BYTES

E4MultipartRequest

public E4MultipartRequest(java.io.PrintWriter debug,
                          java.lang.String strContentTypeText,
                          int intContentLength,
                          java.io.InputStream in,
                          java.lang.String strSaveDirectory,
                          int intMaxReadBytes)
                   throws java.lang.IllegalArgumentException,
                          java.io.IOException,
                          java.io.UnsupportedEncodingException
Deprecated. Replaced by E4MultipartRequest(PrintWriter, String, int, InputStream, String, int, boolean, String)

Standard Constructor

Parameters:
debug - A PrintWriter that can be used for debugging.
strContentTypeText - The "Content-Type" HTTP header value.
intContentLength - The "Content-Length" HTTP header value.
in - The InputStream to read and parse.
strSaveDirectory - The temporary directory to save the file from where they can then be moved to wherever by the calling process. If you specify null for this parameter, then any files uploaded will be silently ignored.
Throws:
java.lang.IllegalArgumentException - If the strContentTypeText does not contain a Content-Type of "multipart/form-data" or the boundary is not found.
java.io.IOException - If the intContentLength is higher than MAX_READ_BYTES or strSaveDirectory is invalid or cannot be written to.
java.io.UnsupportedEncodingException
See Also:
MAX_READ_BYTES

E4MultipartRequest

public E4MultipartRequest(java.io.PrintWriter debug,
                          java.lang.String strContentTypeText,
                          int intContentLength,
                          java.io.InputStream in,
                          java.lang.String strSaveDirectory,
                          int intMaxReadBytes,
                          java.lang.String encoding)
                   throws java.lang.IllegalArgumentException,
                          java.io.IOException,
                          java.io.UnsupportedEncodingException
Standard Constructor

Parameters:
debug - A PrintWriter that can be used for debugging.
strContentTypeText - The "Content-Type" HTTP header value.
intContentLength - The "Content-Length" HTTP header value.
in - The InputStream to read and parse.
strSaveDirectory - The temporary directory to save the file from where they can then be moved to wherever by the calling process. If you specify null for this parameter, then any files uploaded will be silently ignored.
intMaxReadBytes - Overrides the MAX_BYTES_READ value, to allow arbitrarily long files.
encoding - Sets the encoding to use. If null, ISO-8859-1 will be used.
Throws:
java.lang.IllegalArgumentException - If the strContentTypeText does not contain a Content-Type of "multipart/form-data" or the boundary is not found.
java.io.IOException - If the intContentLength is higher than MAX_READ_BYTES or strSaveDirectory is invalid or cannot be written to.
java.io.UnsupportedEncodingException - If the encoding is invalid.
See Also:
MAX_READ_BYTES

E4MultipartRequest

public E4MultipartRequest(java.io.PrintWriter debug,
                          java.lang.String strContentTypeText,
                          int intContentLength,
                          java.io.InputStream in,
                          int intMaxReadBytes,
                          java.lang.String encoding)
                   throws java.lang.IllegalArgumentException,
                          java.io.IOException,
                          java.io.UnsupportedEncodingException
Memory Constructor

Parameters:
debug - A PrintWriter that can be used for debugging.
strContentTypeText - The "Content-Type" HTTP header value.
intContentLength - The "Content-Length" HTTP header value.
in - The InputStream to read and parse.
intMaxReadBytes - Overrides the MAX_BYTES_READ value, to allow arbitrarily long files.
encoding - Sets the encoding to use. If null, ISO-8859-1 will be used.
Throws:
java.lang.IllegalArgumentException - If the strContentTypeText does not contain a Content-Type of "multipart/form-data" or the boundary is not found.
java.io.IOException - If the intContentLength is higher than MAX_READ_BYTES or strSaveDirectory is invalid or cannot be written to.
java.io.UnsupportedEncodingException - If the encoding is invalid.
See Also:
MAX_READ_BYTES

E4MultipartRequest

public E4MultipartRequest(java.io.PrintWriter debug,
                          java.lang.String strContentTypeText,
                          int intContentLength,
                          java.io.InputStream in,
                          java.lang.String strSaveDirectory,
                          int intMaxReadBytes,
                          int maxBytesExceededMode,
                          java.lang.String encoding)
                   throws java.lang.IllegalArgumentException,
                          java.io.IOException,
                          java.io.UnsupportedEncodingException
Standard Constructor

Parameters:
debug - A PrintWriter that can be used for debugging.
strContentTypeText - The "Content-Type" HTTP header value.
intContentLength - The "Content-Length" HTTP header value.
in - The InputStream to read and parse.
strSaveDirectory - The temporary directory to save the file from where they can then be moved to wherever by the calling process. If you specify null for this parameter, then any files uploaded will be silently ignored.
intMaxReadBytes - Overrides the MAX_BYTES_READ value, to allow arbitrarily long files.
maxBytesExceededMode - This controls how the parser will process a request which is in excess of the intMaxReadBytes parameter. The possible modes are:
  • E4MultipartRequest.ABORT_IF_MAX_BYES_EXCEEDED - The parser will throw a MaxBytesReadException
  • E4MultipartRequest.IGNORE_FILES_IF_MAX_BYES_EXCEEDED - All parameters will be processed, but any file content will be discarded. Be warned that there is still potential for Denial-of-Service, if an attacker decided to send megabytes of non-file form data.
    • encoding - Sets the encoding to use. If null, ISO-8859-1 will be used.
      Throws:
      java.lang.IllegalArgumentException - If the strContentTypeText does not contain a Content-Type of "multipart/form-data" or the boundary is not found.
      java.io.IOException - If the intContentLength is higher than MAX_READ_BYTES or strSaveDirectory is invalid or cannot be written to.
      java.io.UnsupportedEncodingException - If the encoding is invalid.
      See Also:
      MAX_READ_BYTES

E4MultipartRequest

public E4MultipartRequest(java.io.PrintWriter debug,
                          java.lang.String strContentTypeText,
                          int intContentLength,
                          java.io.InputStream in,
                          int intMaxReadBytes,
                          int maxBytesExceededMode,
                          java.lang.String encoding)
                   throws java.lang.IllegalArgumentException,
                          java.io.IOException,
                          java.io.UnsupportedEncodingException
Memory Constructor

Parameters:
debug - A PrintWriter that can be used for debugging.
strContentTypeText - The "Content-Type" HTTP header value.
intContentLength - The "Content-Length" HTTP header value.
in - The InputStream to read and parse.
intMaxReadBytes - Overrides the MAX_BYTES_READ value, to allow arbitrarily long files.
maxBytesExceededMode - This controls how the parser will process a request which is in excess of the intMaxReadBytes parameter. The possible modes are:
  • E4MultipartRequest.ABORT_IF_MAX_BYES_EXCEEDED - The parser will throw a MaxBytesReadException
  • E4MultipartRequest.IGNORE_FILES_IF_MAX_BYES_EXCEEDED - All parameters will be processed, but any file content will be discarded. WARNING: There is still potential for a Denial-of-Service. For instance, an attacker can send many megabytes of non-file form data.
    • encoding - Sets the encoding to use. If null, ISO-8859-1 will be used.
      Throws:
      java.lang.IllegalArgumentException - If the strContentTypeText does not contain a Content-Type of "multipart/form-data" or the boundary is not found.
      java.io.IOException - If the intContentLength is higher than MAX_READ_BYTES or strSaveDirectory is invalid or cannot be written to.
      java.io.UnsupportedEncodingException - If the encoding is invalid.
      See Also:
      MAX_READ_BYTES
Method Detail

setEncoding

public void setEncoding(java.lang.String enc)
                 throws java.io.UnsupportedEncodingException
Sets up the encoding for this instance of multipartrequest. You can set the encoding to null, in which case the default encoding will be applied. The default encoding if this method is not called has been set to ISO-8859-1, which seems to offer the best hope of support for international characters, such as german "Umlaut" characters.

Throws:
java.io.UnsupportedEncodingException

getEncoding

public java.lang.String getEncoding()
Returns the current encoding method.


isMaxBytesExceeded

public boolean isMaxBytesExceeded()
If this class was constructed with a maxBytesExceeded mode of E4MultipartRequest.IGNORE_FILES_IF_MAX_BYES_EXCEEDED, this method will indicate whether the process is ignoring file content because the content-length was exceeded.


getURLParameter

public java.lang.String getURLParameter(java.lang.String strName)
Return the value of the strName URLParameter. If more than one value for a particular Parameter, will return the first. If an error occurs will return null.


getURLParameters

public java.util.Enumeration getURLParameters(java.lang.String strName)
Return an enumeration of all values for the strName parameter. Even if a single value for, will always return an enumeration, although it may actually be empty if not value was encountered for strName or it is an invalid parameter name.


getNames

public java.util.Enumeration getNames()
An enumeration of all URL Parameters for the current HTTP Request.


getFileParameterNames

public java.util.Enumeration getFileParameterNames()
This enumeration will return all INPUT TYPE=FILE parameter NAMES as encountered during the upload.


getContentType

public java.lang.String getContentType(java.lang.String strName)
Returns the Content-Type of a file.

See Also:
getFileParameter(java.lang.String, int)

getFileContents

public java.io.InputStream getFileContents(java.lang.String strName)
If files were uploaded into memory, this method will retrieve the contents of the file as a InputStream.

Returns:
the contents of the file as a InputStream, or null if not file uploaded, or file uploaded to file system directory.
See Also:
getFileParameter(java.lang.String, int)

getFile

public java.io.File getFile(java.lang.String strName)
Returns a File reference to the uploaded file. This reference is to the files uploaded location, and allows you to read/move/delete the file. This method is only of use, if files were uploaded to the file system. Will return null if uploaded to memory, in which case you should use getFileContents(strName) instead.

Returns:
Returns a null file reference if a call to getFileSize(strName) returns zero or files were uploaded to memory.
See Also:
getFileSize(java.lang.String), getFileContents(java.lang.String)

getBaseFilename

public java.lang.String getBaseFilename(java.lang.String strName)
Get the uploaded file basename. This is the basename of the file which was provided by the browser itself when the file was chosen using the 'Browse...' button of the <input type=file ...> input field.

Returns:
null if strName not found.
See Also:
getFileParameter(java.lang.String, int)

getRawFilename

public java.lang.String getRawFilename(java.lang.String strName)
Get the uploaded file basename. This is the file which was provided by the browser itself when the file was chosen using the 'Browse...' button of the <input type=file ...> input field.

Returns:
null if strName not found.
See Also:
getFileParameter(java.lang.String, int)

getFileSize

public long getFileSize(java.lang.String strName)
Returns the File Size of a uploaded file.

Returns:
-1 if file size not defined.
See Also:
getFileParameter(java.lang.String, int)

getFileParameter

public java.lang.Object getFileParameter(java.lang.String strName,
                                         int type)
Access an attribute of a file upload parameter record.

Parameters:
strName - is the form field name, used to upload the file. This identifies the formfield location in the storage facility.
type - What attribute you want from the File Parameter.
       The following types are supported:
       E4MultipartRequest.FILENAME, 
       E4MultipartRequest.CONTENT_TYPE, 
       E4MultipartRequest.SIZE,
       E4MultipartRequest.CONTENTS,
       E4MultipartRequest.TMP_FILENAME
       E4MultipartRequest.RAW_FILENAME
 

The getBaseFilename(),getFile(),getFileSize(),getContentType(),getContents() methods all use this method passing in a different type argument.

Note: This class has been changed to provide for future functionality where you will be able to access all files uploaded, even if they are uploaded using the same form field name. At this point however, only the first file uploaded via a form field name is accessible.

See Also:
getContentType(java.lang.String), getFileSize(java.lang.String), getFileContents(java.lang.String), getFile(java.lang.String), getBaseFilename(java.lang.String)

getHtmlTable

public java.lang.String getHtmlTable()
For debugging. Be aware that if you have a form with multiple FILE input types of the same name, only the first one will actually be returned from the getFileParameter(...) method, which all the file access methods call. So if your upload file was actually uploaded against the second file input field, then it will not be accessible, via the methods.


_getSVNVersionString

public static java.lang.String _getSVNVersionString()
Get version info string from subversion.

Returns:
the version info string.
See Also:
E4Util.getRevisionCodeFromSVN(Class)

www.element4solution.com