Forums

Various bugs - upload files, repeaters

healyhatman 17 May, 2018
1) Auto uploading of files do not work when the file field is part of a repeater area, you need to specify each possible field name
For example, in the Custom Files config you would need to enter
documents1:pdf
documents2:pdf
documents3:pdf
...
so on and so forth.

2) Cannot use square brackets in the names of the fields, such as "document[0]"
3) Cannot use curly brackets and therefore cannot use shortcodes in the names of the fields in the custom files list, for example if you were to try and get around issue 1 by putting the upload file action within an Event Loop, and call the field using 'document[{var:loop_event.key}]. Your debug will look a little like the following:
Array
(
    [upload24] => Array
        (
            [path] => /..../components/com_chronoforms6/chronoforms/uploads/
            [document[{var] => Array
                (
                    [extensions] => Array
                        (
                            [0] => loop_event25.key}]:txt
                        )

                    [info] => File is not present.
                )
as you can see, it's a little broken.
dirajmore 26 May, 2018
hello,
Use the mediafinder widget within a repeater because it stores a location of the file and not a database relation. The fileupload widget uses the system_files table and connects via a polymorphic relation to the main record. That type of relationship can't be setup through a repeater's contents, so you'll have to use the mediafinder widget to store the location of the file in the repeater widget's data column.
try this and ping if it helps
regards
diraj
healyhatman 27 May, 2018
Another bug - it says there's been a reply to this post, but I can't see it.
GreyHead 28 May, 2018
1 Likes
Hi healyhatman,

You couldn't see it because it was a first post by a new user and subject to moderation. I did look at it yesterday but didn't understand it - I still don't understand it today :-(

Bob
This topic is locked and no more replies can be posted.