From e9d723fb2c13585fa8a502fde7dd83dc334874ff Mon Sep 17 00:00:00 2001 From: Derek Jones Date: Mon, 12 Jul 2010 10:10:59 -0500 Subject: 201007 file upload bug fix --- user_guide/libraries/file_uploading.html | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-) (limited to 'user_guide/libraries') diff --git a/user_guide/libraries/file_uploading.html b/user_guide/libraries/file_uploading.html index 061d55627..28cf8de3e 100644 --- a/user_guide/libraries/file_uploading.html +++ b/user_guide/libraries/file_uploading.html @@ -28,7 +28,7 @@
- +

CodeIgniter User Guide Version 2.0.0

CodeIgniter User Guide Version 1.7.2

@@ -74,7 +74,7 @@ preferences, restricting the type and size of the files.

  • Once uploaded, the user will be shown a success message.
  • -

    To demonstrate this process here is a brief tutorial. Afterward you'll find reference information.

    +

    To demonstrate this process here is brief tutorial. Afterward you'll find reference information.

    Creating the Upload Form

    @@ -255,7 +255,7 @@ $this->upload->initialize($config); allowed_types None None -The mime types corresponding to the types of files you allow to be uploaded. Usually the file extension can be used as the mime type. Separate multiple types with a pipe. If '*' is used, all file types will be allowed. +The mime types corresponding to the types of files you allow to be uploaded. Usually the file extension can be used as the mime type. Separate multiple types with a pipe. @@ -264,8 +264,7 @@ $this->upload->initialize($config); None Desired file name -

    If set CodeIgniter will rename the uploaded file to this name.

    -

    Note:The filename should not include a file extension.

    +

    If set CodeIgniter will rename the uploaded file to this name. The extension provided in the file name must also be an allowed file type.

    @@ -318,12 +317,6 @@ $this->upload->initialize($config); TRUE/FALSE (boolean) If set to TRUE, any spaces in the file name will be converted to underscores. This is recommended. - -xss_clean -FALSE -TRUE/FALSE (boolean) -If set to TRUE, the files will be tested for XSS vulnerabilities. - @@ -377,6 +370,7 @@ Here is the array prototype:

        [full_path]    => /path/to/your/upload/jpg.jpg
        [raw_name]     => mypic
        [orig_name]    => mypic.jpg
    +    [client_name]  => mypic.jpg
        [file_ext]     => .jpg
        [file_size]    => 22.2
        [is_image]     => 1
    @@ -411,6 +405,9 @@ Here is the array prototype:

    orig_name The original file name. This is only useful if you use the encrypted name option. +client_name +The file name as supplied by the client user agent, prior to any file name preparation or incrementing. + file_ext The file extension with period @@ -447,7 +444,7 @@ Previous Topic:  Encryption Helper User Guide Home   ·   Next Topic:  Form Validation Class

    -

    CodeIgniter  ·  Copyright © 2006-2010  ·  EllisLab, Inc.

    +

    CodeIgniter  ·  Copyright © 2006-2010  ·  Ellislab, Inc.

    -- cgit v1.2.3-24-g4f1b