This class is used to manage file upload using ajax.
More...
|
| | getFullUrl () |
| | Return full URL. More...
|
| |
| | setFileDeleteUrl ($file) |
| | Set delete url. More...
|
| |
| | getFileObject ($file_name) |
| | getFileObject More...
|
| |
| | getFileObjects () |
| | getFileObjects More...
|
| |
| | createScaledImage ($file_name, $options) |
| | Create thumbs of a file uploaded. More...
|
| |
| | validate ($uploaded_file, $file, $error, $index) |
| | Enter description here ... More...
|
| |
| | upcountNameCallback ($matches) |
| | Enter description here ... More...
|
| |
| | upcountName ($name) |
| | Enter description here ... More...
|
| |
| | trimFileName ($name, $type, $index) |
| | trimFileName More...
|
| |
| | handleFileUpload ($uploaded_file, $name, $size, $type, $error, $index) |
| | handleFileUpload More...
|
| |
This class is used to manage file upload using ajax.
Definition at line 31 of file fileupload.class.php.
◆ __construct()
| FileUpload::__construct |
( |
|
$options = null, |
|
|
|
$fk_element = null, |
|
|
|
$element = null |
|
) |
| |
Constructor.
- Parameters
-
| array | $options | Options array |
| int | $fk_element | fk_element |
| string | $element | element |
Definition at line 44 of file fileupload.class.php.
◆ createScaledImage()
| FileUpload::createScaledImage |
( |
|
$file_name, |
|
|
|
$options |
|
) |
| |
|
protected |
Create thumbs of a file uploaded.
Only the "mini" thumb is generated.
- Parameters
-
| string | $file_name | Filename |
| string | $options | is array('max_width', 'max_height') |
- Returns
- boolean
Definition at line 277 of file fileupload.class.php.
◆ delete()
◆ get()
◆ getFileObject()
| FileUpload::getFileObject |
( |
|
$file_name | ) |
|
|
protected |
◆ getFileObjects()
| FileUpload::getFileObjects |
( |
| ) |
|
|
protected |
◆ getFullUrl()
| FileUpload::getFullUrl |
( |
| ) |
|
|
protected |
◆ handleFileUpload()
| FileUpload::handleFileUpload |
( |
|
$uploaded_file, |
|
|
|
$name, |
|
|
|
$size, |
|
|
|
$type, |
|
|
|
$error, |
|
|
|
$index |
|
) |
| |
|
protected |
handleFileUpload
- Parameters
-
| string | $uploaded_file | Uploade file |
| string | $name | Name |
| int | $size | Size |
| string | $type | Type |
| string | $error | Error |
| string | $index | Index |
- Returns
- stdClass
Definition at line 425 of file fileupload.class.php.
◆ post()
◆ setFileDeleteUrl()
| FileUpload::setFileDeleteUrl |
( |
|
$file | ) |
|
|
protected |
◆ trimFileName()
| FileUpload::trimFileName |
( |
|
$name, |
|
|
|
$type, |
|
|
|
$index |
|
) |
| |
|
protected |
trimFileName
- Parameters
-
| string | $name | Filename |
| string | $type | ??? |
| string | $index | ??? |
- Returns
- string
Definition at line 395 of file fileupload.class.php.
◆ upcountName()
| FileUpload::upcountName |
( |
|
$name | ) |
|
|
protected |
◆ upcountNameCallback()
| FileUpload::upcountNameCallback |
( |
|
$matches | ) |
|
|
protected |
◆ validate()
| FileUpload::validate |
( |
|
$uploaded_file, |
|
|
|
$file, |
|
|
|
$error, |
|
|
|
$index |
|
) |
| |
|
protected |
Enter description here ...
- Parameters
-
| string | $uploaded_file | Uploade file |
| object | $file | File |
| string | $error | Error |
| string | $index | Index |
- Returns
- boolean True if OK, False if KO
Definition at line 310 of file fileupload.class.php.
The documentation for this class was generated from the following file: