Closed dkd-kaehm closed 5 years ago
Can you please check this with the latest version available for the plugin? You can use version 3.0.4. I can't reproduce this bug in the latest version.
Hi @haassie, I have the same problem in my installation. I tried to update version from 3.0.0 to 3.0.5 (the latest) but the problems remains. The TYPO3 version is 8.7.22 and for the moment I fix it adding in extension core "&& isset($GLOBALS['TSFE']->page['tx_yoastseo_dont_use'])" in PageMetaRenderer.php line 30 but I'm not sure about this change. Is it the correct way or I do some configuration mistakes? If you want I can do a pull request.. Thanks for your availability.
same bug for me.
Latest version for TYPO3 8.7 ( 3.0.5 )
Caused because $GLOBALS['TSFE']->page is empty string ' ' at some pages. at others $GLOBALS['TSFE']->page = null, so no error.
(have no idea why, but it's default value in TypoScriptFrontendController class is also ' ')
@haassie Found the reason.
$GLOBALS['TSFE']->page is empty string, because standalone view was rendered in tt_content_drawItem hook. (mask extension)
If some of mask CEs was set at page - $GLOBALS['TSFE']->page = ' ' instead of null.
I think there is no reason to continue debugging. TYPO3 core just allow this case, so it must be handled in PageMetaRenderer
Solution from @alessandrofilira looks good for me.
@akhamuliak @alessandrofilira I don't like that solution because, ->page['... is also called in other places, you would have to check everywhere with isset,
For me , this seems to fix it: https://github.com/Yoast/Yoast-SEO-for-TYPO3/pull/447
( but anyways PageMetaRenderer no longer exists I believe, this is a similar issue but for CanonicalGenerator which was causing me error on the backend on the Page module when selecting a page )
By using of modules on different extensions I get exception "Illegal string offset 'tx_yoastseo_dont_use' in ....../PageRenderer/PageMetaRenderer.php line 31" in backend.
For example by clicking on "Function Check" in powermail module. No sence which page is chosen.
https://github.com/Yoast/Yoast-SEO-for-TYPO3/blob/e6b4c3c1c1727c95fa07298fba26aad1b6028f37/Classes/Frontend/PageRenderer/PageMetaRenderer.php#L30
Throwing of such exceptions must be avoided.
How can we reproduce this behavior?
Here is the traceback
Technical info