I'm experiencing a strange problem with extbase/fluid extension creation. I use TYPO3 6.1
I've made an extension with a backend module on my dev server (same configuration/hardware then the prod). The module works perfectly with the path to the template :
myext/Resources/Private/Backend/Templates
myext/Resources/Private/Backend/Layouts
myext/Resources/Private/Backend/Partials
After this, I downloaded my extension's zip in the ext manager and then installer on the prod server. Now I can't use my extension because the module don't find the templates. I've configured the extension by the same way. The templates are in the right path.
I test to move my folder to the parent level :
myext/Resources/Private/Templates
myext/Resources/Private/Layouts
myext/Resources/Private/Partials
With this it works, but in the module configuration, I specify the right path to the "Backend/" folder.
I wont to move my folder in the Private folder, I want it to run in the Private/Backend folder.
I've included the extension static template to the website root TS template.
Here's the constants :
module.tx_myext {
view {
# cat=module.tx_myext/file; type=string; label=Path to template root (BE)
templateRootPath = EXT:wng_myext/Resources/Private/Backend/Templates/
# cat=module.tx_myext/file; type=string; label=Path to template partials (BE)
partialRootPath = EXT:wng_myext/Resources/Private/Backend/Partials/
# cat=module.tx_myext/file; type=string; label=Path to template layouts (BE)
layoutRootPath = EXT:wng_myext/Resources/Private/Backend/Layouts/
}
persistence {
# cat=module.tx_myext//a; type=string; label=Default storage PID
storagePid =
}
}
And here's the setup :
module.tx_myext {
persistence {
storagePid = {$module.tx_myext.persistence.storagePid}
}
view {
templateRootPath = {$module.tx_myext.view.templateRootPath}
partialRootPath = {$module.tx_myext.view.partialRootPath}
layoutRootPath = {$module.tx_myext.view.layoutRootPath}
}
}
Although this thread is quite old I want to show you guys my solution for TYPO3 7.6 LTS.
First you need to include your TypoScript files via
Template > Edit whole record > Includes
.And in your TypoScript you need to use
templateRootPaths.0
instead oftemplateRootPath
:As @benjamin-kott explains, TYPO3's backend modules configurations need to be loaded first. Unfortunately, extension's typoscript files are not automatically loaded by default.
One way of make TYPO3 aware of this typoscript files is creating two files in extension's root folder:
ext_typoscript_constants.txt
ext_typoscript_setup.txt
After adding this files, you should reinstall the extension to see changes. You can use the TypoScript Object Browser to find out if your setup and constants are being loaded.
I dont realy know ur setup, but normaly you must setup these paths in /Configuration/TypoScript/setup.txt like this
This configuration does not being used until you add the static template of your extension. Also you should add these lines to the ext_tables.php
The main problem will be that the typoscript configurations will not get loaded on storage folders or pages without an template in the root path.
Explaination: typoscript configuration you will set for your extension wether it is in ext_typoscript_setup, an static template or via php it will always need an system record template somewhere in the root of the page. otherwise it will not get rendered - and no path settings for your extbase extensions will happen, so the default layout, template and partial path is set and thats the place the script will look for your stuff.
Default is:
if you need to override these for your backendmodule you can work around that problem by injecting the settings for the view directly in your controller.
i hope this helps greetz benji
Try to clean all caches, even in typo3temp/Core/Cache (or something like that)