Project

General

Profile

Actions

Bug #70684

closed

ExtensionManagementUtility::extPath returns different file paths

Added by Christopher Orth over 8 years ago. Updated about 8 years ago.

Status:
Rejected
Priority:
Must have
Assignee:
-
Category:
-
Target version:
-
Start date:
2015-10-14
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
7
PHP Version:
5.5
Tags:
7.5
Complexity:
Is Regression:
No
Sprint Focus:

Description

Hi,

since TYPO3 7.5, \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::extPath(); returns different file paths.

Reproduce:
- Create a dummy extension including a valid TCA
- Edit TCA and add following in ext_tables.php:
$GLOBALS['TCA']['tx_dummy_domain_model_dummy'] = array(
'ctrl' => array(
'dynamicConfigFile' => \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::extPath($_EXTKEY) . 'Configuration/TCA/Dummy.php',
'iconfile' => \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::extRelPath($_EXTKEY) . 'Resources/Public/Icons/tx_dummy_domain_model_dummy.gif'
),
);

Go to the Backend, open "Configuration" check "$GLOBALS[TCA]" Array.
- iconfile will be: "../typo3conf/ext/dummy/Resources/Public/Icons/tx_dummy_domain_model_dummy.gif"
- dynamicConfigFile will be: "/var/www/public/typo3conf/ext/dummy/Configuration/TCA/Dummy.php"

Because of "iconfile" has to be prefixed with "EXT:" the iconfile will never been shown in the Backend List-View.
If you return the complete TCA array in "typo3conf/ext/dummy/Configuration/TCA/tx_dummy_domain_model_dummy.php" instead of set the ctrl array in ext_tables.php "extRelPath()" will return the correct prefixed file paths for both keys (dynamicConfigFile and iconfile)

Best,
Christopher

Actions

Also available in: Atom PDF