Larkis
Larkis

Reputation: 67

Where must finisher files (for powermail finisher) be located?

I am currently trying to add a finisher to my powerplay form.

The target is to delete all elements in a specific folder after the form is submited.

I currently use : this tutorial

I first put this into my setup.txt

plugin.tx_powermail.settings.setup {
finishers {
    1 {
        class = Vendor\Ext\Finisher\DoSomethingFinisher
    }
}

}

at this location: ftp://ftpIP/typo3cms/pagename/typo3conf/ext/powermail/Configuration/TypoScript/Main/setup.txt

Now i should create a PHP-File:

Add a php-file DoSomethingFinisher.php and extend your class with the AbstractFinisher from powermail:

But where shuld I place that PHP File? In the same place as the setup.txt?

Hope someone can help. Thank you very much.

Thomas

Upvotes: 0

Views: 1161

Answers (2)

giraff
giraff

Reputation: 4711

You shouldn't modify the files in the folder powermail, otherwise you will be in trouble when you want to update the extension. Instead, create a new extension with extension_builder or take powermailextended and modify that extension.

Assuming you use powermailextended:

If you call the Finisher In2code\Powermailextended\Finisher\MyFinisher, then it needs to go in EXT:powermailextend\Classes\Finisher\MyFinisher - this is how Typo3 autoloads the PHP files.

Upvotes: 0

Alex Kellner
Alex Kellner

Reputation: 1299

That question is related to TYPO3 autoloading and not to powermail. If you want to add PHP-Files to your TYPO3, you should use an extension. There are some manuals how to get the autoloading to work with your PHP-Files (see https://docs.typo3.org/typo3cms/CoreApiReference/ApiOverview/Autoloading/Index.html).

Upvotes: 2

Related Questions