Giter Site home page Giter Site logo

contao-fineuploader's Introduction

FineUploader Bundle for Contao Open Source CMS

This extension integrates the Fine Uploader by Widen with Contao Open Source CMS.

Installation

Install the package using Composer:

composer require terminal42/contao-fineuploader

Usage

Define the form field as follows:

$GLOBALS['TL_DCA']['tl_table']['fields']['myupload'] = [
    'label'     => &$GLOBALS['TL_LANG']['tl_table']['myupload'],
    'exclude'   => true,
    'inputType' => 'fineUploader',
    'eval'      => [
        'multiple'          => true,                        // Allow multiple files to be uploaded
        'storeFile'         => true,                        // Store the files on the server
        'uploadFolder'      => 'files/uploads',             // Upload target directory (can also be a Contao file system UUID)
        'useHomeDir'        => true,                        // Upload to the current logged in member home directory (overrides "uploadFolder", can also be a Contao file system UUID)
        'uploaderLimit'     => 4,                           // Maximum files that can be uploaded
        'maxConnections'    => 3                            // Maximum allowable concurrent requests
        'addToDbafs'        => true,                        // Add files to the database assisted file system
        'doNotOverwrite'    => true,                        // Do not overwrite files in destination folder
        'debug'             => true                         // Enable the debug mode (always true in development environment)

        // Validation
        'extensions'        => 'pdf,zip',                   // Allowed extension types
        'minlength'         => 1048000,                     // Minimum file size
        'maxlength'         => 2048000,                     // Maximum file size (ignored if you use chunking!)
        'minWidth'          => 400,                         // Minimum image width
        'maxWidth'          => 800,                         // Maximum image width
        'minHeight'         => 300,                         // Minimum image height
        'maxHeight'         => 600,                         // Maximum image height

        // Chunking
        'chunking'          => true,                        // Enable chunking
        'chunkSize'         => 2000000,                     // Chunk size in bytes
        'concurrent'        => true                         // Allow multiple chunks to be uploaded simultaneously per file

        // Rendering
        'imageSize'         => [160, 120, 'center_center'], // Thumbnail image size that is generated upon image upload
        'isGallery'         => true,                        // Display the widget as image gallery
        'isDownloads'       => true,                        // Display the widget as file list
        'sortable'          => true,                        // Make the uploaded files sortable
        'uploadButtonTitle' => 'Upload',                    // Custom upload button title

        // Upload the files directly to the destination folder. If not set, then the files are first uploaded
        // to the temporary folder and moved to the destination folder only when the form is submitted
        'directUpload'      => true,
    ],
    'sql' => "blob NULL"
];

contao-fineuploader's People

Contributors

ameotoko avatar aschempp avatar doishub avatar fritzmg avatar gmpf avatar grbodo avatar jdwiese avatar markocupic avatar paolob avatar qzminski avatar toflar avatar zonky2 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

contao-fineuploader's Issues

File paths in E-Mail are not correct

Hi,

thanks for creating this extension.
As I wanted to use it on a site and I did a bit of testing. There are some issuse with the files and filepaths that are send via e-mail:

Steps to recreate:
set up a form with two upload fields, the upper one for pictures, which are going in one folder and the lower one for audio files which are going into another folder.

  1. In the Url there the path to the file is added to the path with all the / urlencoded, eg:
    http://www.mytest.de/files/test/fotos/files%2Ftest%2Ffotos%2FWeather-Sun-icon.png
  2. Sometimes the path is still the one of the temporary path, even if the file went to it's destiation folder.eg:
    http://www.mytest.de/system/tmp/system%2Ftmp%2FWeather-Sun-icon.png

3.Sometimes the audio file gets moved into the picture folder

It would be nice to have a field where one could chose a prefix for the file name ...

So far so good.
I would try to fix it myself but I do not know where to start...sorry

Auto submitting whole form after onComplete

I wanna implement an option via the onComplete callback of fineuploader in the frontend, but the onComplete event isn't available through standard implementation.
Could you add an option to extend the onComplete Callback?

Formulargenerator

Hi,

Ich benutz euer Datei Upload script im Contao Formulargenerator und bin drauf gekommen das dort nach dem Hochladen das File nicht zum DBAFS hinzugefügt wird.

Fehlt hier für das Widget eventuell noch in der Configuration der "addToDbafs" Key?

Allow to set a custom image upload size

Currently the system's maximum image size is applied to fineuploader. Haste\Util\FileUpload allows to override that.

We should add two fields for width and height to the form field table. If the value is 0 we should take the system default (for backwards compatibility).

Usage?

Hey again,

is this the right way to put the flag (taken from your readme)?

'doNotOvewrite' => true 

I'd assume it's "doNotOverwrite" but both options don't seem to work for me anymore.
Shouldn't it add a number everytime a new image is uploaded with the same name? Like let's say logo.jpg.

I created a BE module where different teams can be created which can have a individual logo. Once choosing logo.jpg for the uploader for each team it uses the same logo for all teams.

Contao 4.4 Test - Crit Error bei Aufruf der Dateiverwaltung

Hallo,

ich habe einmal die Erweiterung unter 4.4 getestet.
Sobald die Erweiterung über den Manager installiert wurde, ist der Aufruf der Dateiverwaltung im Backend nicht mehr möglich und folgender Fehler tritt im Log auf:

[2017-07-07 10:54:59] request.INFO: Matched route "contao_backend". {"route":"contao_backend","route_parameters":{"_scope":"backend","_token_check":true,"_controller":"Contao\CoreBundle\Controller\BackendController::mainAction","_route":"contao_backend"},"request_uri":"https://www.xxx.de/contao?do=files&ref=M3A3-P1a","method":"GET"} []
[2017-07-07 10:54:59] security.INFO: Attempting SimplePreAuthentication. {"key":"backend","authenticator":"Contao\CoreBundle\Security\ContaoAuthenticator"} []
[2017-07-07 10:54:59] request.INFO: Matched route "contao_backend". {"route":"contao_backend","route_parameters":{"_scope":"backend","_token_check":true,"_controller":"Contao\CoreBundle\Controller\BackendController::mainAction","_route":"contao_backend"},"request_uri":"https://www.xxx.de/contao?do=files&ref=M3A3-P1a","method":"GET"} []
[2017-07-07 10:54:59] security.INFO: Attempting SimplePreAuthentication. {"key":"backend","authenticator":"Contao\CoreBundle\Security\ContaoAuthenticator"} []
[2017-07-07 10:54:59] app.CRITICAL: An exception occurred. {"exception":"[object] (Symfony\Component\Debug\Exception\OutOfMemoryException(code: 0): Error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 61039504 bytes) at /www/htdocs/w0070178/contao-4.4/vendor/imagine/imagine/lib/Imagine/Image/Metadata/ExifMetadataReader.php:84)"} []

Alles andere hat soweit funktioniert.
Ein Upload mehrerer Files hat Problemlos geklappt.

//Edit
Contao 4.4
mySQL 7.1

Grüße

Error when attempting to parse xhr response text (Unexpected token < in JSON at position 0)

Been trying to get this running.

Added this to tl_member.php

$GLOBALS['TL_DCA']['tl_member']['fields']['avatarUpload'] = array
(
    'label'                   => &$GLOBALS['TL_LANG']['tl_member']['avatarUpload'],
    'exclude'                 => true,
    'inputType'               => 'fineUploader',
    'eval'                    => array
    (
    	'debug'				=> true,
    	'feEditable'		=> true,
    	'feGroup'			=> 'personal',
    	'tl_class'			=> 'w50 wizard clr',
        'storeFile'         => true,              
        'multiple'          => true,              
        'uploadFolder'      => 'files/uploads',   
        'useHomeDir'        => true,  
        'uploaderConfig'    => "['debug': true]", 
        'uploaderLimit'     => 1,         
        'addToDbafs'        => true,        
        'extensions'        => 'jpg,jpeg,gif,png', 
        'minlength'         => 1024,     
        'maxlength'         => 10240000,     
        'maxWidth'          => 1024,      
        'maxHeight'         => 1024,       
        'doNotOverwrite'    => true,           
        'uploadButtonLabel' => 'Upload images',  

        'chunking'          => true,            
        'chunkSize'         => 2000000,     
        'concurrent'        => true,               
        'maxConnections'    => 30, 
        'directUpload' => false,
        'imageSize'         => [128, 128, 'center_center']
    ),
    'sql'                     => "blob NULL"
);

When I try uploading something in the Front End, it aborts the upload somewhat midway and gives me this error message.
image

Only one filename stored in Session data when uploading multiple files

I want to access the filenames and -paths of all files when uploading multiple files. I am using a custom template on the confirmation page after submitting the form. The problem is, that the ["FILES"] session array (which seems to be created by fineuploader) is always empty after submitting. When I try to access the data of the uploader element in ["FORM_DATA"], only the first filename is available. Is this some sort of bug or am I just using it wrong? I'd appreciate any help!

["FORM_DATA"]["fineuploader"]=>
    string(22) "files/data/filename.xy"

 ["FILES"]=>
  array(0) {
  }

Unlimited uploads

even when I did not activate the multiple option I can upload as many files as I want. Only the first appears after submitting the form though.

How to attach files in efg-emails

I use fineuploader with efg but the uploaded files are not attached to email. Is there an inserttag to use?

Do I have to place the code from README-file in dcaconfig.php?

Fatal error

Hello again ;)

thanks for working on this module continuesly. 👍

I just updated to the newest develop and get this error after choosing a picture:

Fatal error: Call to undefined method Contao\Validator::isBinaryUuid() in 
D:\xampp\htdocs\contao\system\modules\fineuploader\widgets\FineUploaderWidget.php on line 84

Did I miss anything or is it a bug?

Cheers

Delete button is not visible

The delete button (for each image) should have a label (text node). It can still be removed with text-indent. I suggest to use the same as the link title.

Could not find the file list container in the template!

Ich bekommen folgende Fehlermeldung im Backend meines Isotope-Shops, wenn ich ein Produkt bearbeiten möchte:

fineuploader-4.0.3.min.js:3

Uncaught Error: Could not find the file list container in the template!
    at parseAndGetTemplate (fineuploader-4.0.3.min.js:3)
    at new qq.Templating (fineuploader-4.0.3.min.js:3)
    at new qq.FineUploader (fineuploader-4.0.3.min.js:3)
    at Object.Isotope.MediaManager.init (backend.js:514)
    at contao?do=iso_products&act=edit&id=105&rt=l9toWr8IEBgymIR1CkE8O6cmYHyx4LQD45j0nOQQ_kk&ref=xcpAtfaA:352
    at mootools.min.js:1
    at Array.forEach (<anonymous>)
    at Function.forEach (mootools.min.js:1)
    at Array.each (mootools.min.js:1)
    at fireEvent (mootools.min.js:1)

Ich kann auch das Produkt nicht speichern.

Dateien mit Klammern im Dateinamen werden nicht gespeichert

ich versuche ein Bild mit dem fineuploader im Backend hochzuladen mit dem Dateinamen: "images (1).jpg"

Es wird erfolgreich in dem system/tmp Ordner kopiert. Wenn ich jedoch auf "Speichern" drücke wird die Datei nicht in den uploadFolder verschoben.

Dateien mit anderen Dateinamen funktionieren.

dca:
'image' => array(
'label' => & $GLOBALS['TL_LANG']['tl_modul']['image'],
'inputType' => 'fineUploader',
'exclude' => true,
'eval' => array(
'mandatory' => true,
'storeFile' => true, // Mandatory to store the file on the server
'extensions' => "jpg, JPG, jpeg, JPEG", // Allowed extension types
"fieldType" => "radio",
'maxlength' => 2000000, // Maximum file size
"uploadFolder" => "files/uploads"
) ,
'sql' => "blob NULL"
),

Binary issue when uploading file

Warning: pack(): Type H: illegal hex digit s in system/modules/core/library/Contao/String.php on line 538

#0 [internal function]: __error(2, 'pack(): Type H:...', '/var/www/vhosts...', 538, Array)
#1 system/modules/core/library/Contao/String.php(538): pack('H*', 'system/tmp/1.jp...')
#2 system/modules/fineuploader/classes/FineUploader.php(203): Contao\String::uuidToBin('system/tmp/1.jp...')
#3 system/modules/fineuploader/widgets/FineUploaderWidget.php(95): Contao\FineUploader->executeAjaxActions(Array)
#4 system/modules/haste/library/Haste/Form/Form.php(572): Contao\FineUploaderWidget->__construct(Array)
#5 system/modules/haste/library/Haste/Form/Form.php(655): Haste\Form\Form->createWidgets()
#6 system/modules/xxx/library/xxx/Module/Manager/Base.php(144): Haste\Form\Form->addToTemplate(Object(Contao\FrontendTemplate))
#7 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(74): xxx\Module\Manager\Base->compileForm()
#8 system/modules/xxx/library/xxx/Module/Manager/Base.php(82): xxx\Module\Manager\Accessory->compileForm()
#9 system/modules/core/modules/Module.php(148): xxx\Module\Manager\Base->compile()
#10 system/modules/xxx/library/xxx/Module/Manager/Base.php(63): Contao\Module->generate()
#11 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(68): xxx\Module\Manager\Base->generate()
#12 system/modules/core/elements/ContentModule.php(63): xxx\Module\Manager\Accessory->generate()
#13 system/modules/core/library/Contao/Controller.php(481): Contao\ContentModule->generate()
#14 system/modules/core/modules/ModuleArticle.php(208): Contao\Controller->getContentElement(Object(Contao\ContentModel), 'main')
#15 system/modules/core/modules/Module.php(148): Contao\ModuleArticle->compile()
#16 system/modules/core/modules/ModuleArticle.php(59): Contao\Module->generate()
#17 system/modules/core/library/Contao/Controller.php(417): Contao\ModuleArticle->generate(false)
#18 system/modules/core/library/Contao/Controller.php(279): Contao\Controller->getArticle(Object(Contao\ArticleModel), false, false, 'main')
#19 system/modules/core/pages/PageRegular.php(138): Contao\Controller->getFrontendModule('0', 'main')
#20 index.php(246): Contao\PageRegular->generate(Object(Contao\PageModel), true)
#21 index.php(414): Index->run()
#22 {main}


Warning: pack(): Type H: illegal hex digit y in system/modules/core/library/Contao/String.php on line 538

#0 [internal function]: __error(2, 'pack(): Type H:...', '/var/www/vhosts...', 538, Array)
#1 system/modules/core/library/Contao/String.php(538): pack('H*', 'system/tmp/1.jp...')
#2 system/modules/fineuploader/classes/FineUploader.php(203): Contao\String::uuidToBin('system/tmp/1.jp...')
#3 system/modules/fineuploader/widgets/FineUploaderWidget.php(95): Contao\FineUploader->executeAjaxActions(Array)
#4 system/modules/haste/library/Haste/Form/Form.php(572): Contao\FineUploaderWidget->__construct(Array)
#5 system/modules/haste/library/Haste/Form/Form.php(655): Haste\Form\Form->createWidgets()
#6 system/modules/xxx/library/xxx/Module/Manager/Base.php(144): Haste\Form\Form->addToTemplate(Object(Contao\FrontendTemplate))
#7 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(74): xxx\Module\Manager\Base->compileForm()
#8 system/modules/xxx/library/xxx/Module/Manager/Base.php(82): xxx\Module\Manager\Accessory->compileForm()
#9 system/modules/core/modules/Module.php(148): xxx\Module\Manager\Base->compile()
#10 system/modules/xxx/library/xxx/Module/Manager/Base.php(63): Contao\Module->generate()
#11 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(68): xxx\Module\Manager\Base->generate()
#12 system/modules/core/elements/ContentModule.php(63): xxx\Module\Manager\Accessory->generate()
#13 system/modules/core/library/Contao/Controller.php(481): Contao\ContentModule->generate()
#14 system/modules/core/modules/ModuleArticle.php(208): Contao\Controller->getContentElement(Object(Contao\ContentModel), 'main')
#15 system/modules/core/modules/Module.php(148): Contao\ModuleArticle->compile()
#16 system/modules/core/modules/ModuleArticle.php(59): Contao\Module->generate()
#17 system/modules/core/library/Contao/Controller.php(417): Contao\ModuleArticle->generate(false)
#18 system/modules/core/library/Contao/Controller.php(279): Contao\Controller->getArticle(Object(Contao\ArticleModel), false, false, 'main')
#19 system/modules/core/pages/PageRegular.php(138): Contao\Controller->getFrontendModule('0', 'main')
#20 index.php(246): Contao\PageRegular->generate(Object(Contao\PageModel), true)
#21 index.php(414): Index->run()
#22 {main}


Warning: pack(): Type H: illegal hex digit s in system/modules/core/library/Contao/String.php on line 538

#0 [internal function]: __error(2, 'pack(): Type H:...', '/var/www/vhosts...', 538, Array)
#1 system/modules/core/library/Contao/String.php(538): pack('H*', 'system/tmp/1.jp...')
#2 system/modules/fineuploader/classes/FineUploader.php(203): Contao\String::uuidToBin('system/tmp/1.jp...')
#3 system/modules/fineuploader/widgets/FineUploaderWidget.php(95): Contao\FineUploader->executeAjaxActions(Array)
#4 system/modules/haste/library/Haste/Form/Form.php(572): Contao\FineUploaderWidget->__construct(Array)
#5 system/modules/haste/library/Haste/Form/Form.php(655): Haste\Form\Form->createWidgets()
#6 system/modules/xxx/library/xxx/Module/Manager/Base.php(144): Haste\Form\Form->addToTemplate(Object(Contao\FrontendTemplate))
#7 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(74): xxx\Module\Manager\Base->compileForm()
#8 system/modules/xxx/library/xxx/Module/Manager/Base.php(82): xxx\Module\Manager\Accessory->compileForm()
#9 system/modules/core/modules/Module.php(148): xxx\Module\Manager\Base->compile()
#10 system/modules/xxx/library/xxx/Module/Manager/Base.php(63): Contao\Module->generate()
#11 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(68): xxx\Module\Manager\Base->generate()
#12 system/modules/core/elements/ContentModule.php(63): xxx\Module\Manager\Accessory->generate()
#13 system/modules/core/library/Contao/Controller.php(481): Contao\ContentModule->generate()
#14 system/modules/core/modules/ModuleArticle.php(208): Contao\Controller->getContentElement(Object(Contao\ContentModel), 'main')
#15 system/modules/core/modules/Module.php(148): Contao\ModuleArticle->compile()
#16 system/modules/core/modules/ModuleArticle.php(59): Contao\Module->generate()
#17 system/modules/core/library/Contao/Controller.php(417): Contao\ModuleArticle->generate(false)
#18 system/modules/core/library/Contao/Controller.php(279): Contao\Controller->getArticle(Object(Contao\ArticleModel), false, false, 'main')
#19 system/modules/core/pages/PageRegular.php(138): Contao\Controller->getFrontendModule('0', 'main')
#20 index.php(246): Contao\PageRegular->generate(Object(Contao\PageModel), true)
#21 index.php(414): Index->run()
#22 {main}


Warning: pack(): Type H: illegal hex digit t in system/modules/core/library/Contao/String.php on line 538

#0 [internal function]: __error(2, 'pack(): Type H:...', '/var/www/vhosts...', 538, Array)
#1 system/modules/core/library/Contao/String.php(538): pack('H*', 'system/tmp/1.jp...')
#2 system/modules/fineuploader/classes/FineUploader.php(203): Contao\String::uuidToBin('system/tmp/1.jp...')
#3 system/modules/fineuploader/widgets/FineUploaderWidget.php(95): Contao\FineUploader->executeAjaxActions(Array)
#4 system/modules/haste/library/Haste/Form/Form.php(572): Contao\FineUploaderWidget->__construct(Array)
#5 system/modules/haste/library/Haste/Form/Form.php(655): Haste\Form\Form->createWidgets()
#6 system/modules/xxx/library/xxx/Module/Manager/Base.php(144): Haste\Form\Form->addToTemplate(Object(Contao\FrontendTemplate))
#7 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(74): xxx\Module\Manager\Base->compileForm()
#8 system/modules/xxx/library/xxx/Module/Manager/Base.php(82): xxx\Module\Manager\Accessory->compileForm()
#9 system/modules/core/modules/Module.php(148): xxx\Module\Manager\Base->compile()
#10 system/modules/xxx/library/xxx/Module/Manager/Base.php(63): Contao\Module->generate()
#11 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(68): xxx\Module\Manager\Base->generate()
#12 system/modules/core/elements/ContentModule.php(63): xxx\Module\Manager\Accessory->generate()
#13 system/modules/core/library/Contao/Controller.php(481): Contao\ContentModule->generate()
#14 system/modules/core/modules/ModuleArticle.php(208): Contao\Controller->getContentElement(Object(Contao\ContentModel), 'main')
#15 system/modules/core/modules/Module.php(148): Contao\ModuleArticle->compile()
#16 system/modules/core/modules/ModuleArticle.php(59): Contao\Module->generate()
#17 system/modules/core/library/Contao/Controller.php(417): Contao\ModuleArticle->generate(false)
#18 system/modules/core/library/Contao/Controller.php(279): Contao\Controller->getArticle(Object(Contao\ArticleModel), false, false, 'main')
#19 system/modules/core/pages/PageRegular.php(138): Contao\Controller->getFrontendModule('0', 'main')
#20 index.php(246): Contao\PageRegular->generate(Object(Contao\PageModel), true)
#21 index.php(414): Index->run()
#22 {main}


Warning: pack(): Type H: illegal hex digit m in system/modules/core/library/Contao/String.php on line 538

#0 [internal function]: __error(2, 'pack(): Type H:...', '/var/www/vhosts...', 538, Array)
#1 system/modules/core/library/Contao/String.php(538): pack('H*', 'system/tmp/1.jp...')
#2 system/modules/fineuploader/classes/FineUploader.php(203): Contao\String::uuidToBin('system/tmp/1.jp...')
#3 system/modules/fineuploader/widgets/FineUploaderWidget.php(95): Contao\FineUploader->executeAjaxActions(Array)
#4 system/modules/haste/library/Haste/Form/Form.php(572): Contao\FineUploaderWidget->__construct(Array)
#5 system/modules/haste/library/Haste/Form/Form.php(655): Haste\Form\Form->createWidgets()
#6 system/modules/xxx/library/xxx/Module/Manager/Base.php(144): Haste\Form\Form->addToTemplate(Object(Contao\FrontendTemplate))
#7 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(74): xxx\Module\Manager\Base->compileForm()
#8 system/modules/xxx/library/xxx/Module/Manager/Base.php(82): xxx\Module\Manager\Accessory->compileForm()
#9 system/modules/core/modules/Module.php(148): xxx\Module\Manager\Base->compile()
#10 system/modules/xxx/library/xxx/Module/Manager/Base.php(63): Contao\Module->generate()
#11 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(68): xxx\Module\Manager\Base->generate()
#12 system/modules/core/elements/ContentModule.php(63): xxx\Module\Manager\Accessory->generate()
#13 system/modules/core/library/Contao/Controller.php(481): Contao\ContentModule->generate()
#14 system/modules/core/modules/ModuleArticle.php(208): Contao\Controller->getContentElement(Object(Contao\ContentModel), 'main')
#15 system/modules/core/modules/Module.php(148): Contao\ModuleArticle->compile()
#16 system/modules/core/modules/ModuleArticle.php(59): Contao\Module->generate()
#17 system/modules/core/library/Contao/Controller.php(417): Contao\ModuleArticle->generate(false)
#18 system/modules/core/library/Contao/Controller.php(279): Contao\Controller->getArticle(Object(Contao\ArticleModel), false, false, 'main')
#19 system/modules/core/pages/PageRegular.php(138): Contao\Controller->getFrontendModule('0', 'main')
#20 index.php(246): Contao\PageRegular->generate(Object(Contao\PageModel), true)
#21 index.php(414): Index->run()
#22 {main}


Warning: pack(): Type H: illegal hex digit / in system/modules/core/library/Contao/String.php on line 538

#0 [internal function]: __error(2, 'pack(): Type H:...', '/var/www/vhosts...', 538, Array)
#1 system/modules/core/library/Contao/String.php(538): pack('H*', 'system/tmp/1.jp...')
#2 system/modules/fineuploader/classes/FineUploader.php(203): Contao\String::uuidToBin('system/tmp/1.jp...')
#3 system/modules/fineuploader/widgets/FineUploaderWidget.php(95): Contao\FineUploader->executeAjaxActions(Array)
#4 system/modules/haste/library/Haste/Form/Form.php(572): Contao\FineUploaderWidget->__construct(Array)
#5 system/modules/haste/library/Haste/Form/Form.php(655): Haste\Form\Form->createWidgets()
#6 system/modules/xxx/library/xxx/Module/Manager/Base.php(144): Haste\Form\Form->addToTemplate(Object(Contao\FrontendTemplate))
#7 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(74): xxx\Module\Manager\Base->compileForm()
#8 system/modules/xxx/library/xxx/Module/Manager/Base.php(82): xxx\Module\Manager\Accessory->compileForm()
#9 system/modules/core/modules/Module.php(148): xxx\Module\Manager\Base->compile()
#10 system/modules/xxx/library/xxx/Module/Manager/Base.php(63): Contao\Module->generate()
#11 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(68): xxx\Module\Manager\Base->generate()
#12 system/modules/core/elements/ContentModule.php(63): xxx\Module\Manager\Accessory->generate()
#13 system/modules/core/library/Contao/Controller.php(481): Contao\ContentModule->generate()
#14 system/modules/core/modules/ModuleArticle.php(208): Contao\Controller->getContentElement(Object(Contao\ContentModel), 'main')
#15 system/modules/core/modules/Module.php(148): Contao\ModuleArticle->compile()
#16 system/modules/core/modules/ModuleArticle.php(59): Contao\Module->generate()
#17 system/modules/core/library/Contao/Controller.php(417): Contao\ModuleArticle->generate(false)
#18 system/modules/core/library/Contao/Controller.php(279): Contao\Controller->getArticle(Object(Contao\ArticleModel), false, false, 'main')
#19 system/modules/core/pages/PageRegular.php(138): Contao\Controller->getFrontendModule('0', 'main')
#20 index.php(246): Contao\PageRegular->generate(Object(Contao\PageModel), true)
#21 index.php(414): Index->run()
#22 {main}


Warning: pack(): Type H: illegal hex digit t in system/modules/core/library/Contao/String.php on line 538

#0 [internal function]: __error(2, 'pack(): Type H:...', '/var/www/vhosts...', 538, Array)
#1 system/modules/core/library/Contao/String.php(538): pack('H*', 'system/tmp/1.jp...')
#2 system/modules/fineuploader/classes/FineUploader.php(203): Contao\String::uuidToBin('system/tmp/1.jp...')
#3 system/modules/fineuploader/widgets/FineUploaderWidget.php(95): Contao\FineUploader->executeAjaxActions(Array)
#4 system/modules/haste/library/Haste/Form/Form.php(572): Contao\FineUploaderWidget->__construct(Array)
#5 system/modules/haste/library/Haste/Form/Form.php(655): Haste\Form\Form->createWidgets()
#6 system/modules/xxx/library/xxx/Module/Manager/Base.php(144): Haste\Form\Form->addToTemplate(Object(Contao\FrontendTemplate))
#7 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(74): xxx\Module\Manager\Base->compileForm()
#8 system/modules/xxx/library/xxx/Module/Manager/Base.php(82): xxx\Module\Manager\Accessory->compileForm()
#9 system/modules/core/modules/Module.php(148): xxx\Module\Manager\Base->compile()
#10 system/modules/xxx/library/xxx/Module/Manager/Base.php(63): Contao\Module->generate()
#11 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(68): xxx\Module\Manager\Base->generate()
#12 system/modules/core/elements/ContentModule.php(63): xxx\Module\Manager\Accessory->generate()
#13 system/modules/core/library/Contao/Controller.php(481): Contao\ContentModule->generate()
#14 system/modules/core/modules/ModuleArticle.php(208): Contao\Controller->getContentElement(Object(Contao\ContentModel), 'main')
#15 system/modules/core/modules/Module.php(148): Contao\ModuleArticle->compile()
#16 system/modules/core/modules/ModuleArticle.php(59): Contao\Module->generate()
#17 system/modules/core/library/Contao/Controller.php(417): Contao\ModuleArticle->generate(false)
#18 system/modules/core/library/Contao/Controller.php(279): Contao\Controller->getArticle(Object(Contao\ArticleModel), false, false, 'main')
#19 system/modules/core/pages/PageRegular.php(138): Contao\Controller->getFrontendModule('0', 'main')
#20 index.php(246): Contao\PageRegular->generate(Object(Contao\PageModel), true)
#21 index.php(414): Index->run()
#22 {main}


Warning: pack(): Type H: illegal hex digit m in system/modules/core/library/Contao/String.php on line 538

#0 [internal function]: __error(2, 'pack(): Type H:...', '/var/www/vhosts...', 538, Array)
#1 system/modules/core/library/Contao/String.php(538): pack('H*', 'system/tmp/1.jp...')
#2 system/modules/fineuploader/classes/FineUploader.php(203): Contao\String::uuidToBin('system/tmp/1.jp...')
#3 system/modules/fineuploader/widgets/FineUploaderWidget.php(95): Contao\FineUploader->executeAjaxActions(Array)
#4 system/modules/haste/library/Haste/Form/Form.php(572): Contao\FineUploaderWidget->__construct(Array)
#5 system/modules/haste/library/Haste/Form/Form.php(655): Haste\Form\Form->createWidgets()
#6 system/modules/xxx/library/xxx/Module/Manager/Base.php(144): Haste\Form\Form->addToTemplate(Object(Contao\FrontendTemplate))
#7 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(74): xxx\Module\Manager\Base->compileForm()
#8 system/modules/xxx/library/xxx/Module/Manager/Base.php(82): xxx\Module\Manager\Accessory->compileForm()
#9 system/modules/core/modules/Module.php(148): xxx\Module\Manager\Base->compile()
#10 system/modules/xxx/library/xxx/Module/Manager/Base.php(63): Contao\Module->generate()
#11 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(68): xxx\Module\Manager\Base->generate()
#12 system/modules/core/elements/ContentModule.php(63): xxx\Module\Manager\Accessory->generate()
#13 system/modules/core/library/Contao/Controller.php(481): Contao\ContentModule->generate()
#14 system/modules/core/modules/ModuleArticle.php(208): Contao\Controller->getContentElement(Object(Contao\ContentModel), 'main')
#15 system/modules/core/modules/Module.php(148): Contao\ModuleArticle->compile()
#16 system/modules/core/modules/ModuleArticle.php(59): Contao\Module->generate()
#17 system/modules/core/library/Contao/Controller.php(417): Contao\ModuleArticle->generate(false)
#18 system/modules/core/library/Contao/Controller.php(279): Contao\Controller->getArticle(Object(Contao\ArticleModel), false, false, 'main')
#19 system/modules/core/pages/PageRegular.php(138): Contao\Controller->getFrontendModule('0', 'main')
#20 index.php(246): Contao\PageRegular->generate(Object(Contao\PageModel), true)
#21 index.php(414): Index->run()
#22 {main}


Warning: pack(): Type H: illegal hex digit p in system/modules/core/library/Contao/String.php on line 538

#0 [internal function]: __error(2, 'pack(): Type H:...', '/var/www/vhosts...', 538, Array)
#1 system/modules/core/library/Contao/String.php(538): pack('H*', 'system/tmp/1.jp...')
#2 system/modules/fineuploader/classes/FineUploader.php(203): Contao\String::uuidToBin('system/tmp/1.jp...')
#3 system/modules/fineuploader/widgets/FineUploaderWidget.php(95): Contao\FineUploader->executeAjaxActions(Array)
#4 system/modules/haste/library/Haste/Form/Form.php(572): Contao\FineUploaderWidget->__construct(Array)
#5 system/modules/haste/library/Haste/Form/Form.php(655): Haste\Form\Form->createWidgets()
#6 system/modules/xxx/library/xxx/Module/Manager/Base.php(144): Haste\Form\Form->addToTemplate(Object(Contao\FrontendTemplate))
#7 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(74): xxx\Module\Manager\Base->compileForm()
#8 system/modules/xxx/library/xxx/Module/Manager/Base.php(82): xxx\Module\Manager\Accessory->compileForm()
#9 system/modules/core/modules/Module.php(148): xxx\Module\Manager\Base->compile()
#10 system/modules/xxx/library/xxx/Module/Manager/Base.php(63): Contao\Module->generate()
#11 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(68): xxx\Module\Manager\Base->generate()
#12 system/modules/core/elements/ContentModule.php(63): xxx\Module\Manager\Accessory->generate()
#13 system/modules/core/library/Contao/Controller.php(481): Contao\ContentModule->generate()
#14 system/modules/core/modules/ModuleArticle.php(208): Contao\Controller->getContentElement(Object(Contao\ContentModel), 'main')
#15 system/modules/core/modules/Module.php(148): Contao\ModuleArticle->compile()
#16 system/modules/core/modules/ModuleArticle.php(59): Contao\Module->generate()
#17 system/modules/core/library/Contao/Controller.php(417): Contao\ModuleArticle->generate(false)
#18 system/modules/core/library/Contao/Controller.php(279): Contao\Controller->getArticle(Object(Contao\ArticleModel), false, false, 'main')
#19 system/modules/core/pages/PageRegular.php(138): Contao\Controller->getFrontendModule('0', 'main')
#20 index.php(246): Contao\PageRegular->generate(Object(Contao\PageModel), true)
#21 index.php(414): Index->run()
#22 {main}


Warning: pack(): Type H: illegal hex digit / in system/modules/core/library/Contao/String.php on line 538

#0 [internal function]: __error(2, 'pack(): Type H:...', '/var/www/vhosts...', 538, Array)
#1 system/modules/core/library/Contao/String.php(538): pack('H*', 'system/tmp/1.jp...')
#2 system/modules/fineuploader/classes/FineUploader.php(203): Contao\String::uuidToBin('system/tmp/1.jp...')
#3 system/modules/fineuploader/widgets/FineUploaderWidget.php(95): Contao\FineUploader->executeAjaxActions(Array)
#4 system/modules/haste/library/Haste/Form/Form.php(572): Contao\FineUploaderWidget->__construct(Array)
#5 system/modules/haste/library/Haste/Form/Form.php(655): Haste\Form\Form->createWidgets()
#6 system/modules/xxx/library/xxx/Module/Manager/Base.php(144): Haste\Form\Form->addToTemplate(Object(Contao\FrontendTemplate))
#7 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(74): xxx\Module\Manager\Base->compileForm()
#8 system/modules/xxx/library/xxx/Module/Manager/Base.php(82): xxx\Module\Manager\Accessory->compileForm()
#9 system/modules/core/modules/Module.php(148): xxx\Module\Manager\Base->compile()
#10 system/modules/xxx/library/xxx/Module/Manager/Base.php(63): Contao\Module->generate()
#11 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(68): xxx\Module\Manager\Base->generate()
#12 system/modules/core/elements/ContentModule.php(63): xxx\Module\Manager\Accessory->generate()
#13 system/modules/core/library/Contao/Controller.php(481): Contao\ContentModule->generate()
#14 system/modules/core/modules/ModuleArticle.php(208): Contao\Controller->getContentElement(Object(Contao\ContentModel), 'main')
#15 system/modules/core/modules/Module.php(148): Contao\ModuleArticle->compile()
#16 system/modules/core/modules/ModuleArticle.php(59): Contao\Module->generate()
#17 system/modules/core/library/Contao/Controller.php(417): Contao\ModuleArticle->generate(false)
#18 system/modules/core/library/Contao/Controller.php(279): Contao\Controller->getArticle(Object(Contao\ArticleModel), false, false, 'main')
#19 system/modules/core/pages/PageRegular.php(138): Contao\Controller->getFrontendModule('0', 'main')
#20 index.php(246): Contao\PageRegular->generate(Object(Contao\PageModel), true)
#21 index.php(414): Index->run()
#22 {main}


Warning: pack(): Type H: illegal hex digit . in system/modules/core/library/Contao/String.php on line 538

#0 [internal function]: __error(2, 'pack(): Type H:...', '/var/www/vhosts...', 538, Array)
#1 system/modules/core/library/Contao/String.php(538): pack('H*', 'system/tmp/1.jp...')
#2 system/modules/fineuploader/classes/FineUploader.php(203): Contao\String::uuidToBin('system/tmp/1.jp...')
#3 system/modules/fineuploader/widgets/FineUploaderWidget.php(95): Contao\FineUploader->executeAjaxActions(Array)
#4 system/modules/haste/library/Haste/Form/Form.php(572): Contao\FineUploaderWidget->__construct(Array)
#5 system/modules/haste/library/Haste/Form/Form.php(655): Haste\Form\Form->createWidgets()
#6 system/modules/xxx/library/xxx/Module/Manager/Base.php(144): Haste\Form\Form->addToTemplate(Object(Contao\FrontendTemplate))
#7 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(74): xxx\Module\Manager\Base->compileForm()
#8 system/modules/xxx/library/xxx/Module/Manager/Base.php(82): xxx\Module\Manager\Accessory->compileForm()
#9 system/modules/core/modules/Module.php(148): xxx\Module\Manager\Base->compile()
#10 system/modules/xxx/library/xxx/Module/Manager/Base.php(63): Contao\Module->generate()
#11 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(68): xxx\Module\Manager\Base->generate()
#12 system/modules/core/elements/ContentModule.php(63): xxx\Module\Manager\Accessory->generate()
#13 system/modules/core/library/Contao/Controller.php(481): Contao\ContentModule->generate()
#14 system/modules/core/modules/ModuleArticle.php(208): Contao\Controller->getContentElement(Object(Contao\ContentModel), 'main')
#15 system/modules/core/modules/Module.php(148): Contao\ModuleArticle->compile()
#16 system/modules/core/modules/ModuleArticle.php(59): Contao\Module->generate()
#17 system/modules/core/library/Contao/Controller.php(417): Contao\ModuleArticle->generate(false)
#18 system/modules/core/library/Contao/Controller.php(279): Contao\Controller->getArticle(Object(Contao\ArticleModel), false, false, 'main')
#19 system/modules/core/pages/PageRegular.php(138): Contao\Controller->getFrontendModule('0', 'main')
#20 index.php(246): Contao\PageRegular->generate(Object(Contao\PageModel), true)
#21 index.php(414): Index->run()
#22 {main}


Warning: pack(): Type H: illegal hex digit j in system/modules/core/library/Contao/String.php on line 538

#0 [internal function]: __error(2, 'pack(): Type H:...', '/var/www/vhosts...', 538, Array)
#1 system/modules/core/library/Contao/String.php(538): pack('H*', 'system/tmp/1.jp...')
#2 system/modules/fineuploader/classes/FineUploader.php(203): Contao\String::uuidToBin('system/tmp/1.jp...')
#3 system/modules/fineuploader/widgets/FineUploaderWidget.php(95): Contao\FineUploader->executeAjaxActions(Array)
#4 system/modules/haste/library/Haste/Form/Form.php(572): Contao\FineUploaderWidget->__construct(Array)
#5 system/modules/haste/library/Haste/Form/Form.php(655): Haste\Form\Form->createWidgets()
#6 system/modules/xxx/library/xxx/Module/Manager/Base.php(144): Haste\Form\Form->addToTemplate(Object(Contao\FrontendTemplate))
#7 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(74): xxx\Module\Manager\Base->compileForm()
#8 system/modules/xxx/library/xxx/Module/Manager/Base.php(82): xxx\Module\Manager\Accessory->compileForm()
#9 system/modules/core/modules/Module.php(148): xxx\Module\Manager\Base->compile()
#10 system/modules/xxx/library/xxx/Module/Manager/Base.php(63): Contao\Module->generate()
#11 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(68): xxx\Module\Manager\Base->generate()
#12 system/modules/core/elements/ContentModule.php(63): xxx\Module\Manager\Accessory->generate()
#13 system/modules/core/library/Contao/Controller.php(481): Contao\ContentModule->generate()
#14 system/modules/core/modules/ModuleArticle.php(208): Contao\Controller->getContentElement(Object(Contao\ContentModel), 'main')
#15 system/modules/core/modules/Module.php(148): Contao\ModuleArticle->compile()
#16 system/modules/core/modules/ModuleArticle.php(59): Contao\Module->generate()
#17 system/modules/core/library/Contao/Controller.php(417): Contao\ModuleArticle->generate(false)
#18 system/modules/core/library/Contao/Controller.php(279): Contao\Controller->getArticle(Object(Contao\ArticleModel), false, false, 'main')
#19 system/modules/core/pages/PageRegular.php(138): Contao\Controller->getFrontendModule('0', 'main')
#20 index.php(246): Contao\PageRegular->generate(Object(Contao\PageModel), true)
#21 index.php(414): Index->run()
#22 {main}


Warning: pack(): Type H: illegal hex digit p in system/modules/core/library/Contao/String.php on line 538

#0 [internal function]: __error(2, 'pack(): Type H:...', '/var/www/vhosts...', 538, Array)
#1 system/modules/core/library/Contao/String.php(538): pack('H*', 'system/tmp/1.jp...')
#2 system/modules/fineuploader/classes/FineUploader.php(203): Contao\String::uuidToBin('system/tmp/1.jp...')
#3 system/modules/fineuploader/widgets/FineUploaderWidget.php(95): Contao\FineUploader->executeAjaxActions(Array)
#4 system/modules/haste/library/Haste/Form/Form.php(572): Contao\FineUploaderWidget->__construct(Array)
#5 system/modules/haste/library/Haste/Form/Form.php(655): Haste\Form\Form->createWidgets()
#6 system/modules/xxx/library/xxx/Module/Manager/Base.php(144): Haste\Form\Form->addToTemplate(Object(Contao\FrontendTemplate))
#7 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(74): xxx\Module\Manager\Base->compileForm()
#8 system/modules/xxx/library/xxx/Module/Manager/Base.php(82): xxx\Module\Manager\Accessory->compileForm()
#9 system/modules/core/modules/Module.php(148): xxx\Module\Manager\Base->compile()
#10 system/modules/xxx/library/xxx/Module/Manager/Base.php(63): Contao\Module->generate()
#11 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(68): xxx\Module\Manager\Base->generate()
#12 system/modules/core/elements/ContentModule.php(63): xxx\Module\Manager\Accessory->generate()
#13 system/modules/core/library/Contao/Controller.php(481): Contao\ContentModule->generate()
#14 system/modules/core/modules/ModuleArticle.php(208): Contao\Controller->getContentElement(Object(Contao\ContentModel), 'main')
#15 system/modules/core/modules/Module.php(148): Contao\ModuleArticle->compile()
#16 system/modules/core/modules/ModuleArticle.php(59): Contao\Module->generate()
#17 system/modules/core/library/Contao/Controller.php(417): Contao\ModuleArticle->generate(false)
#18 system/modules/core/library/Contao/Controller.php(279): Contao\Controller->getArticle(Object(Contao\ArticleModel), false, false, 'main')
#19 system/modules/core/pages/PageRegular.php(138): Contao\Controller->getFrontendModule('0', 'main')
#20 index.php(246): Contao\PageRegular->generate(Object(Contao\PageModel), true)
#21 index.php(414): Index->run()
#22 {main}


Warning: pack(): Type H: illegal hex digit g in system/modules/core/library/Contao/String.php on line 538

#0 [internal function]: __error(2, 'pack(): Type H:...', '/var/www/vhosts...', 538, Array)
#1 system/modules/core/library/Contao/String.php(538): pack('H*', 'system/tmp/1.jp...')
#2 system/modules/fineuploader/classes/FineUploader.php(203): Contao\String::uuidToBin('system/tmp/1.jp...')
#3 system/modules/fineuploader/widgets/FineUploaderWidget.php(95): Contao\FineUploader->executeAjaxActions(Array)
#4 system/modules/haste/library/Haste/Form/Form.php(572): Contao\FineUploaderWidget->__construct(Array)
#5 system/modules/haste/library/Haste/Form/Form.php(655): Haste\Form\Form->createWidgets()
#6 system/modules/xxx/library/xxx/Module/Manager/Base.php(144): Haste\Form\Form->addToTemplate(Object(Contao\FrontendTemplate))
#7 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(74): xxx\Module\Manager\Base->compileForm()
#8 system/modules/xxx/library/xxx/Module/Manager/Base.php(82): xxx\Module\Manager\Accessory->compileForm()
#9 system/modules/core/modules/Module.php(148): xxx\Module\Manager\Base->compile()
#10 system/modules/xxx/library/xxx/Module/Manager/Base.php(63): Contao\Module->generate()
#11 system/modules/xxx/library/xxx/Module/Manager/Accessory.php(68): xxx\Module\Manager\Base->generate()
#12 system/modules/core/elements/ContentModule.php(63): xxx\Module\Manager\Accessory->generate()
#13 system/modules/core/library/Contao/Controller.php(481): Contao\ContentModule->generate()
#14 system/modules/core/modules/ModuleArticle.php(208): Contao\Controller->getContentElement(Object(Contao\ContentModel), 'main')
#15 system/modules/core/modules/Module.php(148): Contao\ModuleArticle->compile()
#16 system/modules/core/modules/ModuleArticle.php(59): Contao\Module->generate()
#17 system/modules/core/library/Contao/Controller.php(417): Contao\ModuleArticle->generate(false)
#18 system/modules/core/library/Contao/Controller.php(279): Contao\Controller->getArticle(Object(Contao\ArticleModel), false, false, 'main')
#19 system/modules/core/pages/PageRegular.php(138): Contao\Controller->getFrontendModule('0', 'main')
#20 index.php(246): Contao\PageRegular->generate(Object(Contao\PageModel), true)
#21 index.php(414): Index->run()
#22 {main}

Maxlength (and minlength) can be zero

In the form generator, an "empy" value for minlength and maxlength equals "ignore this". Currently if maxlength is 0, no files can be uploaded due to file size limit.

Feature Request: Submit button label configurable?

It would be useful if the submit button label ("Upload a file") would be configurable like in the standard contao form. I know that this might be possible with the help of the DCA but not for different labels in one form like one with "PDF Upload" and another one with "Image Upload".

Can't remove successful uploads

If I uploaded a file (without submitting the form), I can't remove the download (to maybe replace it with something else).

There seems to be an invisible qq-upload-delete button, maybe that's a configuration?

Upload failed

Hi.
I've made a custom extension "catalog" for image upload I would like to use fineuploader.

When I upload image I get an error "Upload failed".
image

And console error.
image

The images are uploaded to system/tmp.

Field configuration

            'label'                   => &$GLOBALS['TL_LANG']['tl_table']['myupload'],
            'exclude'                 => true,
            'inputType'               => 'fineUploader',
            'eval'                    => array
            (
                'storeFile'         => true,                // Mandatory to store the file on the server
                'multiple'          => true,                // Allow multiple files to be uploaded
                'uploadFolder'      => 'files/tmp',         // Upload target directory (can also be a Contao file system UUID)
                'useHomeDir'        => true,                // Upload to the FE member home directory (overrides "uploadFolder", can also be a Contao file system UUID)
                'uploaderConfig'    => "['debug': true]",   // Custom uploader configuration that gets merged with the other params
                'uploaderLimit'     => 4,                   // Maximum files that can be uploaded
                'addToDbafs'        => true,                // Add files to the database assisted file system
                'extensions'        => 'jpg,png,gif',           // Allowed extension types
                'minlength'         => 1048,                    // Minimum file size
                'maxlength'         => 204800000,             // Maximum file size (is ignored if you use chunking!)
                'maxWidth'          => 8000,                 // Maximum width (applies to images only)
                'maxHeight'         => 6000,                 // Maximum height (applies to images only)
                'doNotOverwrite'    => true,                // Do not overwrite files in destination folder
                'uploadButtonLabel' => 'Upload images',     // Custom upload button label

                'chunking'          => false,                // Enable chunking
                'chunkSize'         => 2000000,             // Chunk size in bytes
                'concurrent'        => true,                 // Allow multiple chunks to be uploaded simultaneously per file
                'maxConnections'    => 3,                    // Maximum allowable concurrent requests
                'directUpload'      => false,
            ),
            'sql'                     => "blob NULL"

I'm using Contao 3.5.36.

Feature Request: dynamischer uploadFolder

Hi,

wäre es möglich den UploadFolder dynamisch zu konfigurieren? Nützlich wäre es einen String für

  • date()
    oder
  • sprintf() mit Referenz auf z.B. ein weiteres Textfeld/Headline/o.ä. des gleichen Eintrages

angeben zu können. Der neue Ordner müsste natürlich auch automatisch angelegt werden. Man hätte so etwas mehr Ordnung auf dem Server und füllt nicht ein Verzeichnis, welches dann hunderte von Dateien beinhaltet.

Progress bar display issue

If I select an invalid file type (e.g. PSD but only JPEG is allowed), the progress bar container becomes visible and won't hide.

Fineuploader im Subpalette einblenden über Checkbox submitObChange=true Handler

Wenn der Fineuploader im Subpalette über den DCA definiert ist und dieses Subpalette über eine Checkbox eingeblendet wird, wird der "Datei hochladen"-Button nicht angezeigt.

Erst durch erneutes Laden der Seite wird der "Datei hochladen" Button angezeigt.

dca:

'palettes' => array(
'selector' => array('addImages'),
'default' => 'addImages'
) ,
'subpalettes' => array
(
'addImages' => 'images'
),

'fields' => array(
"addImages" => array(
'label' => & $GLOBALS['TL_LANG']['tl_module']['addImages'],
'inputType' => 'checkbox',
'exclude' => true,
'eval' => array('submitOnChange'=>true),
'sql' => "char(1) NOT NULL default ''"
),
'images' => array(
'label' => & $GLOBALS['TL_LANG']['tl_module']['images'],
'inputType' => 'fineUploader',
'exclude' => true,
'eval' => array(
"mandatory" => true,
"multiple" => true,
"fieldType" => "checkbox",
'storeFile' => true, // Mandatory to store the file on the server
'extensions' => "jpg,JPG,jpeg,JPEG", // Allowed extension types
'maxlength' => 2000000, // Maximum file size
) ,
'sql' => "blob NULL"
),
)
);

Contao 4.2 compatibility

Please test on Contao 4 and see if we need to adjust anything, also for the new backend theme. Then we need to adjust composer dependencies.

typo in README.md

It should be

'doNotOverwrite' => …

instead of

'doNotOvewrite' => …

:)

Update to FineUploader 5.10

  • Use npm and gulp to update and minify the files so it's easier to update in the future
  • Release extension v 1.1 (if compatible) or 2.0 (if not compatible)

Submitting forum doesn't move files to destination folder

Hey,

just updated to the newest release (develop) and the bugs I reported earlier are gone, Thanks!

But I just came across another problem: The uploaded files aren't moved to the destination folder after submitting the form anymore.

Did the anything change so it doesn't use

'uploadFolder'          => 'files/uploads', // Upload path (destination folder)

anymore?

Cheers

Uploading does not replace image

If I submit the form after an upload, and the form has errors, I get a preview of the just-uploaded picture. If I then upload another picture, it's simply ignored. I guess it should replace the existing one? Or not allow to upload until I deleted?

Form submit while upload

It should not be possible to submit the form while a large file is uploading.

Suggestions:

  1. find input[type=submit'] and set disabled
  2. add form onSubmit handler to show an alert message (blabla… wait for upload finish…)

Describe the backend form field options

I can't figure out what all the backend options do, we should add that to the README.

  • What's "Field size", which seems not related to multiple uploads?
  • What would "Maximum connections" do, and why would I ever set it? What will a value of 0 result in?

Files not stored in defined UploadFolder

Hi Kamil,

I'm using the Fineuploader via DCA Field in my Backend-Module. After the Upload (i see the path /system/tmp/somefilename.pdf) i try to save. The Files i have uploaded before saving isn't stored in defined Upload Folder. The files stored only in the folder /system/tmp.

Is there something wrong with my configuration? I'm using Contao 3.2.16.

Thanx for your help :)

UploadLimit = 1 - bug?!

Hey there,

not sure if it's just me, but if I set the 'uploaderLimit' to '1'

 'uploaderLimit' => 1,

the BE form always says the limit is exceeded and doesn't upload the file (picking 1 file for upload).
Setting the limit to 2 and picking 2 files works fine including upload.

Can anyone report the same problem?

Cheers

Feature Request: deep-delete (Lösche Datei auch auf dem Server)

Hi,

zur Zeit experimentiere ich damit, eine Galerie mit madeyourday/contao-rocksolid-custom-elements zu erstellen (was mir dank dem Support dort nun gelungen ist). Allein das "Aufräumen" ist noch nicht befriedigend gelöst. Ich habe Sorge, dass der Server nach längerem Gebrauch Dateileichen vorhält, obwohl die darüberliegenden Elemente schon lange gelöscht sind. Soweit ich verstanden haben, ist das Hochladen eine Einbahnstraße. Nach dem erstmaligen Speichern eines Eintrages sind die Dateien im DBAFS (wenn addToDbafs true), ins Zielverzeichnis verschoben und das Feld von contao-fineuploader zeigt die bisher ausgewählten Dateien. Soweit gut. Die Dateien verbleiben aber auf dem Server bis man über die Dateiverwaltung die Einträge löscht.

Könnte man das javascript hinter ContaoFineUploader.deleteItem() so anpassen, dass die gewählte Datei auch vom Server gelöscht wird? Am besten konfigurierbar (nur aus Liste entfernen / löschen mit Rückfrage / sofort löschen).

Etwas weiter würden folgende Löschanweisungen gehen:

  • zusätzlicher "Alle Löschen" button
  • wenn ein Eintrag z.B. ein Artikel gelöscht wird, der ein contao-fineuploader Feld beinhaltet, werden alle zugeordneten Dateien mit gelöscht.

Das würde den Kreis schließen und man müsste nicht den Server nach Dateileichen durchsuchen (okay, wäre sicherlich per Script lösbar, aber bliebe ein Workaround).

Warning: is_file()

Hallo,

cooles Widget, dass ihr da zur Verfügung stellt. Danke schon mal dafür 👍

Ich habe es gerade entdeckt und das erste mal in einer eigenen Erweiterung getestet unter Contao 3.3

Das Bild wird auch hochgeladen und auch an der entsprechenden Stelle gespeichert.
Allerdings wird dann im BE ein Fehler ausgegeben:

Warning: is_file() expects parameter 1 to be a valid path, string 
given in C:\xampp\htdocs\contao33\system\modules\fineuploader\widgets
\FineUploaderWidget.php on line 404

#0 [internal function]: __error(2, 'is_file() expec...', 'C:\xampp\htdocs...', 404, Array)
#1 C:\xampp\htdocs\contao33\system\modules\fineuploader\widgets\FineUploaderWidget.php(404): is_file('C:\xampp\htdocs...')
#2 C:\xampp\htdocs\contao33\system\modules\core\library\Contao\Widget.php(607): Contao\FineUploaderWidget->generate()
#3 C:\xampp\htdocs\contao33\system\modules\core\templates\backend\be_widget.html5(3): Contao\Widget->generateWithError(true)
#4 C:\xampp\htdocs\contao33\system\modules\core\library\Contao\BaseTemplate.php(92): include('C:\xampp\htdocs...')
#5 C:\xampp\htdocs\contao33\system\modules\core\library\Contao\Widget.php(553): Contao\BaseTemplate->parse()
#6 C:\xampp\htdocs\contao33\system\modules\core\classes\DataContainer.php(520): Contao\Widget->parse()
#7 C:\xampp\htdocs\contao33\system\modules\core\drivers\DC_Table.php(1868): Contao\DataContainer->row('{team_legend},t...')
#8 C:\xampp\htdocs\contao33\system\modules\core\classes\Backend.php(568): Contao\DC_Table->edit()
#9 C:\xampp\htdocs\contao33\contao\main.php(142): Contao\Backend->getBackendModule('team-management')
#10 C:\xampp\htdocs\contao33\contao\main.php(293): Main->run()
#11 {main}

Habe ich dort noch etwas falsch eingestellt?
Außerdem habe ich noch eine Frage: Kann ich das Bild beim Upload verkleinern lassen, falls es eine gewisse Größe überschreitet?

Besten Griß,
Sebi

'directUpload' => true wird ignoriert

Egal ob 'true' or 'false', die Datei(en) werden immer erst ins system/tmp geladen und erst nach dem Speichern in das angegebene Zielverzeichnis verschoben. Hier meine DCA-Konfiguration:

(
'storeFile' => true,
'multiple' => true,
'uploadFolder' => $strTargetFolder, (wird vorher ermittelt/gesetzt)
'uploaderLimit' => 10,
'addToDbafs' => true,
'extensions' => 'pdf,xls,xlsx,xlsm,doc,docx,ppt,pptx,zip,mov,mp3,mp4',
'minlength' => 1024,
'maxlength' => 2048000,
'doNotOverwrite' => false,
'maxConnections' => 3,
'directUpload' => true,
),

Add minlength support

The minlength field should behave the same as maxlength, it defines the minimum file size in bytes.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.