How to create a folder picker

Permalink
Is there any helper function available for setup a folder picker like file picker ?

midhunsaffron
 
MrKDilkington replied on at Permalink Best Answer Reply
MrKDilkington
Hi midhunsaffron,

There is a FileFolderSelector widget.
https://github.com/concrete5/concrete5/blob/develop/concrete/src/For...

Here is an example of it being used in the Express Form block:
<div class="form-group">
    <label class="control-label"><?=t('Add uploaded files to folder')?></label>
    <?php
    $selector = new \Concrete\Core\Form\Service\Widget\FileFolderSelector();
    echo $selector->selectFileFolder('addFilesToFolder', $addFilesToFolder);
    ?>
</div>

https://github.com/concrete5/concrete5/blob/develop/concrete/blocks/...

I am not sure on the specifics of how it is used though.
midhunsaffron replied on at Permalink Reply
midhunsaffron
Hi MrKDilkington,

It works good, thanks