Enabling PHP file uploads in TYPO3 Backend

Total
0
Shares

At one project i’m working on i had to upload php files in a TYPO3 backend form. But the form was just throwing me the message that php files are not allowed as uploads. After some digging i found the solution to this problem. Actually it’s quite easy to fix.

The only thing you need to do is to add the following configurations directives into TYPO3’s localconf.php file:

$TYPO3_CONF_VARS['BE']['fileExtensions']['webspace']['allow'] = 'php';
$TYPO3_CONF_VARS['BE']['fileExtensions']['webspace']['deny'] = '';
$TYPO3_CONF_VARS['BE']['fileDenyPattern'] = '';

After you did this you should clear the cache and you should be able to upload php files.

NOTE: Allow upload of php files only in situations when you know for sure that these are files or users that can be trusted. Allowing the upload of unverified php files by untrusted users poses a GREAT SECURITY RISK!

2 comments
Leave a Reply

Your email address will not be published. Required fields are marked *

You May Also Like