Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Explode error in typo3 7.6 with compatibility6 #10

Open
jul6art opened this issue Mar 28, 2017 · 0 comments
Open

Explode error in typo3 7.6 with compatibility6 #10

jul6art opened this issue Mar 28, 2017 · 0 comments

Comments

@jul6art
Copy link

jul6art commented Mar 28, 2017

I've got errors after update from typo3 6.2 to typo3 7.6 with compatibility6 mode enabled.

In the backend, when i need to edit page or article, the content is not charged in the textareas and i've got this warning

PHP Warning
Core: Error handler (BE): PHP Warning: explode() expects parameter 2 to be string, array given in /home/typo3/typo3_src-7.6.16/typo3/sysext/core/Classes/Utility/GeneralUtility.php line 1556

To try to debug it, i put a test in the trimExplode function of typo3 like this:


if(is_array($string)){
    $e = new \Exception();
    $error_string = $e->getTraceAsString();
    $f = fopen('/var/www/html/custom.log', 'a+');
    fputs($f, PHP_EOL . "new line" . PHP_EOL);
    fputs($f, PHP_EOL . $error_string . PHP_EOL);
    fputs($f, PHP_EOL . print_r($string) . PHP_EOL);
    fclose($f);
}

But the stacktrace that i get is not enough clear for me to understand what's wrong. The array is empty and so, i think the problem is not the array, but is in compatibility6. Does anybody know what's the problem with compatibility6? Here's the stacktrace

new line
#0 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Form/FormDataProvider/AbstractItemProvider.php(1142): TYPO3\CMS\Core\Utility\GeneralUtility::trimExplode(',', Array, true)
#1 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Form/FormDataProvider/TcaSelectItems.php(75): TYPO3\CMS\Backend\Form\FormDataProvider\AbstractItemProvider->processDatabaseFieldValue(Array, 'field_auto_head...')
#2 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Form/FormDataGroup/FlexFormSegment.php(51): TYPO3\CMS\Backend\Form\FormDataProvider\TcaSelectItems->addData(Array)
#3 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Form/FormDataCompiler.php(99): TYPO3\CMS\Backend\Form\FormDataGroup\FlexFormSegment->compile(Array)
#4 /var/www/html/typo3conf/ext/compatibility6/Classes/Form/FormDataProvider/TcaFlexProcess.php(549): TYPO3\CMS\Backend\Form\FormDataCompiler->compile(Array)
#5 /var/www/html/typo3conf/ext/compatibility6/Classes/Form/FormDataProvider/TcaFlexProcess.php(54): TYPO3\CMS\Compatibility6\Form\FormDataProvider\TcaFlexProcess->modifyDataStructureAndDataValuesByFlexFormSegmentGroup(Array, 'tx_templavoila_...', Array)
#6 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Form/FormDataGroup/TcaDatabaseRecord.php(51): TYPO3\CMS\Compatibility6\Form\FormDataProvider\TcaFlexProcess->addData(Array)
#7 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Form/FormDataCompiler.php(99): TYPO3\CMS\Backend\Form\FormDataGroup\TcaDatabaseRecord->compile(Array)
#8 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Controller/EditDocumentController.php(1118): TYPO3\CMS\Backend\Form\FormDataCompiler->compile(Array)
#9 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Controller/EditDocumentController.php(1009): TYPO3\CMS\Backend\Controller\EditDocumentController->makeEditForm()
#10 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Controller/EditDocumentController.php(2043): TYPO3\CMS\Backend\Controller\EditDocumentController->main()
#11 [internal function]: TYPO3\CMS\Backend\Controller\EditDocumentController->mainAction(Object(TYPO3\CMS\Core\Http\ServerRequest), Object(TYPO3\CMS\Core\Http\Response))
#12 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Http/RouteDispatcher.php(54): call_user_func_array(Array, Array)
#13 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Http/RequestHandler.php(168): TYPO3\CMS\Backend\Http\RouteDispatcher->dispatch(Object(TYPO3\CMS\Core\Http\ServerRequest), Object(TYPO3\CMS\Core\Http\Response))
#14 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Http/RequestHandler.php(95): TYPO3\CMS\Backend\Http\RequestHandler->dispatch(Object(TYPO3\CMS\Core\Http\ServerRequest))
#15 /home/typo3/typo3_src-7.6.16/typo3/sysext/core/Classes/Core/Bootstrap.php(302): TYPO3\CMS\Backend\Http\RequestHandler->handleRequest(Object(TYPO3\CMS\Core\Http\ServerRequest))
#16 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Http/Application.php(94): TYPO3\CMS\Core\Core\Bootstrap->handleRequest(Object(TYPO3\CMS\Core\Http\ServerRequest))
#17 /home/typo3/typo3_src-7.6.16/typo3/index.php(20): TYPO3\CMS\Backend\Http\Application->run()
#18 [internal function]: {closure}()
#19 /home/typo3/typo3_src-7.6.16/typo3/index.php(21): call_user_func(Object(Closure))
#20 {main}

1

new line

#0 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Form/FormDataProvider/AbstractItemProvider.php(1142): TYPO3\CMS\Core\Utility\GeneralUtility::trimExplode(',', Array, true)
#1 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Form/FormDataProvider/TcaSelectItems.php(75): TYPO3\CMS\Backend\Form\FormDataProvider\AbstractItemProvider->processDatabaseFieldValue(Array, 'field_feature_b...')
#2 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Form/FormDataGroup/FlexFormSegment.php(51): TYPO3\CMS\Backend\Form\FormDataProvider\TcaSelectItems->addData(Array)
#3 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Form/FormDataCompiler.php(99): TYPO3\CMS\Backend\Form\FormDataGroup\FlexFormSegment->compile(Array)
#4 /var/www/html/typo3conf/ext/compatibility6/Classes/Form/FormDataProvider/TcaFlexProcess.php(549): TYPO3\CMS\Backend\Form\FormDataCompiler->compile(Array)
#5 /var/www/html/typo3conf/ext/compatibility6/Classes/Form/FormDataProvider/TcaFlexProcess.php(54): TYPO3\CMS\Compatibility6\Form\FormDataProvider\TcaFlexProcess->modifyDataStructureAndDataValuesByFlexFormSegmentGroup(Array, 'tx_templavoila_...', Array)
#6 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Form/FormDataGroup/TcaDatabaseRecord.php(51): TYPO3\CMS\Compatibility6\Form\FormDataProvider\TcaFlexProcess->addData(Array)
#7 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Form/FormDataCompiler.php(99): TYPO3\CMS\Backend\Form\FormDataGroup\TcaDatabaseRecord->compile(Array)
#8 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Controller/EditDocumentController.php(1118): TYPO3\CMS\Backend\Form\FormDataCompiler->compile(Array)
#9 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Controller/EditDocumentController.php(1009): TYPO3\CMS\Backend\Controller\EditDocumentController->makeEditForm()
#10 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Controller/EditDocumentController.php(2043): TYPO3\CMS\Backend\Controller\EditDocumentController->main()
#11 [internal function]: TYPO3\CMS\Backend\Controller\EditDocumentController->mainAction(Object(TYPO3\CMS\Core\Http\ServerRequest), Object(TYPO3\CMS\Core\Http\Response))
#12 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Http/RouteDispatcher.php(54): call_user_func_array(Array, Array)
#13 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Http/RequestHandler.php(168): TYPO3\CMS\Backend\Http\RouteDispatcher->dispatch(Object(TYPO3\CMS\Core\Http\ServerRequest), Object(TYPO3\CMS\Core\Http\Response))
#14 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Http/RequestHandler.php(95): TYPO3\CMS\Backend\Http\RequestHandler->dispatch(Object(TYPO3\CMS\Core\Http\ServerRequest))
#15 /home/typo3/typo3_src-7.6.16/typo3/sysext/core/Classes/Core/Bootstrap.php(302): TYPO3\CMS\Backend\Http\RequestHandler->handleRequest(Object(TYPO3\CMS\Core\Http\ServerRequest))
#16 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Http/Application.php(94): TYPO3\CMS\Core\Core\Bootstrap->handleRequest(Object(TYPO3\CMS\Core\Http\ServerRequest))
#17 /home/typo3/typo3_src-7.6.16/typo3/index.php(20): TYPO3\CMS\Backend\Http\Application->run()
#18 [internal function]: {closure}()
#19 /home/typo3/typo3_src-7.6.16/typo3/index.php(21): call_user_func(Object(Closure))
#20 {main}

1

new line

#0 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Form/FormDataProvider/AbstractItemProvider.php(1142): TYPO3\CMS\Core\Utility\GeneralUtility::trimExplode(',', Array, true)
#1 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Form/FormDataProvider/TcaSelectItems.php(75): TYPO3\CMS\Backend\Form\FormDataProvider\AbstractItemProvider->processDatabaseFieldValue(Array, 'recursive')
#2 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Form/FormDataGroup/FlexFormSegment.php(51): TYPO3\CMS\Backend\Form\FormDataProvider\TcaSelectItems->addData(Array)
#3 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Form/FormDataCompiler.php(99): TYPO3\CMS\Backend\Form\FormDataGroup\FlexFormSegment->compile(Array)
#4 /var/www/html/typo3conf/ext/compatibility6/Classes/Form/FormDataProvider/TcaFlexProcess.php(549): TYPO3\CMS\Backend\Form\FormDataCompiler->compile(Array)
#5 /var/www/html/typo3conf/ext/compatibility6/Classes/Form/FormDataProvider/TcaFlexProcess.php(54): TYPO3\CMS\Compatibility6\Form\FormDataProvider\TcaFlexProcess->modifyDataStructureAndDataValuesByFlexFormSegmentGroup(Array, 'pi_flexform', Array)
#6 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Form/FormDataGroup/TcaDatabaseRecord.php(51): TYPO3\CMS\Compatibility6\Form\FormDataProvider\TcaFlexProcess->addData(Array)
#7 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Form/FormDataCompiler.php(99): TYPO3\CMS\Backend\Form\FormDataGroup\TcaDatabaseRecord->compile(Array)
#8 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Controller/EditDocumentController.php(1118): TYPO3\CMS\Backend\Form\FormDataCompiler->compile(Array)
#9 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Controller/EditDocumentController.php(1009): TYPO3\CMS\Backend\Controller\EditDocumentController->makeEditForm()
#10 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Controller/EditDocumentController.php(2043): TYPO3\CMS\Backend\Controller\EditDocumentController->main()
#11 [internal function]: TYPO3\CMS\Backend\Controller\EditDocumentController->mainAction(Object(TYPO3\CMS\Core\Http\ServerRequest), Object(TYPO3\CMS\Core\Http\Response))
#12 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Http/RouteDispatcher.php(54): call_user_func_array(Array, Array)
#13 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Http/RequestHandler.php(168): TYPO3\CMS\Backend\Http\RouteDispatcher->dispatch(Object(TYPO3\CMS\Core\Http\ServerRequest), Object(TYPO3\CMS\Core\Http\Response))
#14 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Http/RequestHandler.php(95): TYPO3\CMS\Backend\Http\RequestHandler->dispatch(Object(TYPO3\CMS\Core\Http\ServerRequest))
#15 /home/typo3/typo3_src-7.6.16/typo3/sysext/core/Classes/Core/Bootstrap.php(302): TYPO3\CMS\Backend\Http\RequestHandler->handleRequest(Object(TYPO3\CMS\Core\Http\ServerRequest))
#16 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Http/Application.php(94): TYPO3\CMS\Core\Core\Bootstrap->handleRequest(Object(TYPO3\CMS\Core\Http\ServerRequest))
#17 /home/typo3/typo3_src-7.6.16/typo3/index.php(20): TYPO3\CMS\Backend\Http\Application->run()
#18 [internal function]: {closure}()
#19 /home/typo3/typo3_src-7.6.16/typo3/index.php(21): call_user_func(Object(Closure))
#20 {main}

1

new line

#0 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Form/FormDataProvider/AbstractItemProvider.php(1142): TYPO3\CMS\Core\Utility\GeneralUtility::trimExplode(',', Array, true)
#1 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Form/FormDataProvider/TcaSelectItems.php(75): TYPO3\CMS\Backend\Form\FormDataProvider\AbstractItemProvider->processDatabaseFieldValue(Array, 'template')
#2 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Form/FormDataGroup/FlexFormSegment.php(51): TYPO3\CMS\Backend\Form\FormDataProvider\TcaSelectItems->addData(Array)
#3 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Form/FormDataCompiler.php(99): TYPO3\CMS\Backend\Form\FormDataGroup\FlexFormSegment->compile(Array)
#4 /var/www/html/typo3conf/ext/compatibility6/Classes/Form/FormDataProvider/TcaFlexProcess.php(549): TYPO3\CMS\Backend\Form\FormDataCompiler->compile(Array)
#5 /var/www/html/typo3conf/ext/compatibility6/Classes/Form/FormDataProvider/TcaFlexProcess.php(54): TYPO3\CMS\Compatibility6\Form\FormDataProvider\TcaFlexProcess->modifyDataStructureAndDataValuesByFlexFormSegmentGroup(Array, 'pi_flexform', Array)
#6 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Form/FormDataGroup/TcaDatabaseRecord.php(51): TYPO3\CMS\Compatibility6\Form\FormDataProvider\TcaFlexProcess->addData(Array)
#7 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Form/FormDataCompiler.php(99): TYPO3\CMS\Backend\Form\FormDataGroup\TcaDatabaseRecord->compile(Array)
#8 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Controller/EditDocumentController.php(1118): TYPO3\CMS\Backend\Form\FormDataCompiler->compile(Array)
#9 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Controller/EditDocumentController.php(1009): TYPO3\CMS\Backend\Controller\EditDocumentController->makeEditForm()
#10 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Controller/EditDocumentController.php(2043): TYPO3\CMS\Backend\Controller\EditDocumentController->main()
#11 [internal function]: TYPO3\CMS\Backend\Controller\EditDocumentController->mainAction(Object(TYPO3\CMS\Core\Http\ServerRequest), Object(TYPO3\CMS\Core\Http\Response))
#12 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Http/RouteDispatcher.php(54): call_user_func_array(Array, Array)
#13 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Http/RequestHandler.php(168): TYPO3\CMS\Backend\Http\RouteDispatcher->dispatch(Object(TYPO3\CMS\Core\Http\ServerRequest), Object(TYPO3\CMS\Core\Http\Response))
#14 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Http/RequestHandler.php(95): TYPO3\CMS\Backend\Http\RequestHandler->dispatch(Object(TYPO3\CMS\Core\Http\ServerRequest))
#15 /home/typo3/typo3_src-7.6.16/typo3/sysext/core/Classes/Core/Bootstrap.php(302): TYPO3\CMS\Backend\Http\RequestHandler->handleRequest(Object(TYPO3\CMS\Core\Http\ServerRequest))
#16 /home/typo3/typo3_src-7.6.16/typo3/sysext/backend/Classes/Http/Application.php(94): TYPO3\CMS\Core\Core\Bootstrap->handleRequest(Object(TYPO3\CMS\Core\Http\ServerRequest))
#17 /home/typo3/typo3_src-7.6.16/typo3/index.php(20): TYPO3\CMS\Backend\Http\Application->run()
#18 [internal function]: {closure}()
#19 /home/typo3/typo3_src-7.6.16/typo3/index.php(21): call_user_func(Object(Closure))
#20 {main}

1

Thank you for any response or help.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant