Bug #102380
closedResolve correct page UID in BackendConfigurationManager
0%
Description
Hello,
we have two Root pages:
- Rootpage A
- Rootpage B
As these rootpages are very different in their structure and layout we have build very individual TS templates, pageTSconfig and permissions. Example: On rootpage we have EXT:solr with normal list results, but on rootpage we have a Google Map where POIs can be filtered by Solr. So, we need another fluid template for solr output on rootpage B. This fluid template should not be available for rootpage A.
EXT:solr comes with a special TS to add further fluid templates into template selector of solr plugin (ContentElement in BE) (plugin.tx_solr.view.templateFiles.results.availableTemplates.*). I make use of that possibility for rootpage B, while this configuration is empty for rootpage A.
The problem:
While editing the solr plugin on rootpage B my TS configured fluid template was not added to the list of available templates in selector. And this is not a solr problem. It's an extbase problem.
As we are in TYPO3 BE the BackendConfigurationManager::getTypoScriptSetup() will be called to retrieve the current TSFE. As this method does not provide a PID argument, Extbase now "tries" to find a PID. At first it tries to get a PID from $_GET. It will not find anything, as we are editing a content element where no PID is in URL. At next i will try to retrieve a PID by method getCurrentPageIdFromCurrentSiteRoot(). This method name has nothing to do with the content of that method, as just the FIRST (A) rootpage will be fetched and returned. So solr works with TSFE from rootpage A from now on where my special setting is not available of cause.
I remember a method in TYPO3 API years ago, where TYPO3 tries to retrieve the PID from returnURL parameter. Maybe we can add such a check into BackendConfigurationManager, too.
Stefan
Updated by Stefan Froemken 9 months ago
- Related to Bug #93251: getCurrentPageId not working correctly in multisite systems added
Updated by Stefan Froemken 9 months ago
- Related to Bug #88572: ConfigurationManager returns wrong configuration added
Updated by Georg Ringer about 2 months ago
- Related to Bug #104150: Default Form configuration not always loaded for EXT:form added