Hello everyone,
When I submit a file in filemanager and generate link, works well
But when access the filemanager again, passing the same context, component, itemid
I can't see the file to override it.
$draftitemid = file_get_submitted_draft_itemid('attachments');
file_prepare_draft_area($draftitemid, $context->id, 'block_myblock, 'attachment', $itemid, $filemanageropts);
To save I use:
file_save_draft_area_files($draftitemid, $context->id, 'block_myblock, 'attachment', $itemid, $filemanageropts);
I need only open the filemanager and see the uploaded before and override it.
What is wrong?