Bug #27957
closedTCA tree somehow causes fatal error when using in inline record (IRRE)
100%
Description
Hello folks!
When using the following configuration for
a select field rendered as tree, it's neither
possible to expand inline records, nor to create
new inline records, because the page renderer,
called through the AJAX request, throws an
exception - also mentioned below.
'included_categories' => array( 'exclude' => 1, 'label' => 'LLL:EXT:hype_store/Resources/Private/Language/locallang_db.xml:tx_hypestore_domain_model_discount.included_categories', 'config' => array( 'type' => 'select', 'foreign_table' => 'tx_hypestore_domain_model_category', 'MM' => 'tx_hypestore_relation_discount_category', 'MM_opposite_field' => 'discounts', 'MM_match_fields' => array( 'exclude' => 0 ), 'minitems' => 0, 'maxitems' => 999999, 'renderMode' => 'tree', 'treeConfig' => array( 'parentField' => 'parent_category', 'appearance' => array( 'expandAll' => TRUE, 'showHeader' => TRUE ), ), ), )
The error thrown (ajax response) is...
#1284906026: Language and character encoding are not set.
... which occurs in the file class.t3lib_pagerenderer.php in line 1795.
If I remove the "TCA tree configuration" everything works. The tree also
works, if the record is opened directly. If opened as inline record,
the described behaviour occurs.
Files
Updated by Thomas Deinhamer about 13 years ago
Sorry, the code part seems to be corrupted, hope you get the point anyway.
Updated by Steffen Ritter about 13 years ago
- Category changed from 978 to FormEngine aka TCEforms
- Status changed from New to Accepted
- Assignee set to Steffen Ritter
Updated by Oliver Hader about 13 years ago
- Target version changed from 4.5.4 to 4.5.6
Updated by Andreas Wolf almost 13 years ago
- Status changed from Accepted to Needs Feedback
- Target version changed from 4.5.6 to 4.5.7
I could not reproduce this - maybe I'm missing some knowledge about the different IRRE ways here... could you provide a demo extension with a minimum required TCA to reproduce this?
Updated by Alexander Jahn almost 13 years ago
- File T3X_inline500error.t3x T3X_inline500error.t3x added
It seems i've ran into the same issue today.
I threw together a simple demo extension as a demonstration. I guess my problem has the same cause as Thomas'.
Install the extension regularily and create a new tt_content record in some page.
Open record, then in tab 'ERROR 500 DEMO' create a new inline record
=> throws error 500, systemLog reports exception #1284906026
In tca.php disable rendering of tca tree in line 28 and creating / expanding of records works
In ext_tables.php line 19 set collapseAll to 0 and existing records show up fine when tca tree is used.
Updated by Chris topher almost 13 years ago
- Target version changed from 4.5.7 to 4.5.8
Updated by Georg Ringer over 12 years ago
just experienced that too with 4-5-8 ... this didn't occur in older versions of 4-5
Updated by Ernesto Baschny over 12 years ago
- Target version changed from 4.5.8 to 4.5.12
Updated by Gerrit Code Review over 12 years ago
- Status changed from Needs Feedback to Under Review
Patch set 1 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/9874
Updated by Laurent Cherpit over 12 years ago
Same problem with version 4.6 branch.
The charset property is not defined when the page renderer is cloned.
workaround would to set the charset:
/** * Gets the JavaScript of the pageRenderer. * This can be used to extract newly added files which have been added * during an AJAX request. Due to the spread possibilities of the pageRenderer * to add JavaScript rendering and extracting seems to be the easiest way. * * @return string */ protected function getJavaScriptAndStyleSheetsOfPageRenderer() { /** @var $pageRenderer t3lib_PageRenderer */ $pageRenderer = clone $GLOBALS['SOBE']->doc->getPageRenderer(); $pageRenderer->setCharSet($GLOBALS['LANG']->charSet); $pageRenderer->setTemplateFile(TYPO3_mainDir . 'templates/helper_javascript_css.html'); $javaScriptAndStyleSheets = $pageRenderer->render(); return $javaScriptAndStyleSheets; }
Updated by Gerrit Code Review over 12 years ago
Patch set 2 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/9874
Updated by Gerrit Code Review over 12 years ago
Patch set 3 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/9874
Updated by Gerrit Code Review over 12 years ago
Patch set 4 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/9874
Updated by Gerrit Code Review almost 12 years ago
Patch set 1 for branch TYPO3_4-7 has been pushed to the review server.
It is available at http://review.typo3.org/14245
Updated by Gerrit Code Review almost 12 years ago
Patch set 5 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/9874
Updated by Gerrit Code Review almost 12 years ago
Patch set 1 for branch TYPO3_4-6 has been pushed to the review server.
It is available at http://review.typo3.org/14246
Updated by Gerrit Code Review almost 12 years ago
Patch set 1 for branch TYPO3_4-5 has been pushed to the review server.
It is available at http://review.typo3.org/14247
Updated by Xavier Perseguers almost 12 years ago
- Status changed from Under Review to Resolved
- Assignee changed from Steffen Ritter to Xavier Perseguers
- Target version changed from 4.5.12 to 6.0.0-beta2
- % Done changed from 0 to 100
Updated by Riccardo De Contardi almost 7 years ago
- Status changed from Resolved to Closed