TYPO3 v15 dev-main snapshot ()

This commit is contained in:
2026-08-10 22:31:24 +02:00
commit aad9daaefd
1506 changed files with 94005 additions and 0 deletions
@@ -0,0 +1,48 @@
.. include:: /Includes.rst.txt
.. _concepts-finishers-deleteuploadsfinisher:
.. _finishers-delete-uploads:
=======================
DeleteUploads finishers
=======================
The "DeleteUploads finisher" removes files that have been submitted. You can use this
finisher after the email finisher if you do not want to keep the files
in your TYPO3 installation.
.. note::
Finishers are only executed when a form is successfully submitted. If a user uploads
a file but does not finish filling out the form, the uploaded files will not
be deleted.
.. contents:: Table of contents
.. include:: /Includes/_NoteFinisher.rst
.. _concepts-finishers-deleteuploadsfinisher-yaml:
DeleteUploads finisher in the YAML form definition
==================================================
Use this finisher after the email finisher if you do not want to keep the files
in your TYPO3 installation.
Finishers are executed in the order they are listed in the form definition
YAML file:
.. literalinclude:: _codesnippets/_form.yaml
:caption: public/fileadmin/forms/my_form.yaml
.. _apireference-finisheroptions-deleteuploadsfinisher:
Using the DeleteUploads finisher in PHP code
============================================
Developers can use the finisher key `DeleteUploads` to create
deleteuploads finishers in their own classes:
.. literalinclude:: _codesnippets/_finisher.php.inc
:language: php
This finisher is implemented in :php:`TYPO3\CMS\Form\Domain\Finishers\DeleteUploadsFinisher`.
@@ -0,0 +1,11 @@
<?php
use TYPO3\CMS\Form\Domain\Model\FormDefinition;
class SomeClass
{
private function addDeleteUploadsFinisherWithMessage(FormDefinition $formDefinition, string $message)
{
$formDefinition->createFinisher('DeleteUploads');
}
}
@@ -0,0 +1,13 @@
identifier: example-form
label: 'example'
type: Form
finishers:
-
identifier: EmailToSender
options:
subject: 'Your Message: {message}'
-
identifier: DeleteUploads
# Define the delete uploads finisher AFTER the email finisher
# ...