Yoast / Yoast-SEO-for-TYPO3

Yoast SEO plugin for TYPO3
Other
51 stars 56 forks source link

make new typo3 composer mode work #494

Closed ghost closed 2 years ago

ghost commented 2 years ago

@haassie i just fix it on my own

RinyVT commented 2 years ago

Hi, thanks for the PR! But, seeing as TYPO3 handles these paths in the core: https://github.com/TYPO3/typo3/blob/11.5/typo3/sysext/core/Classes/Utility/PathUtility.php#L63

I think it's enough to move the Resources/Public inside the getAbsoluteWebPaths calls? So instead of:

$publicResourcesPath =
                PathUtility::getAbsoluteWebPath(ExtensionManagementUtility::extPath('yoast_seo')) . 'Resources/Public/';

It would be:

$publicResourcesPath =
                PathUtility::getAbsoluteWebPath(ExtensionManagementUtility::extPath('yoast_seo') . 'Resources/Public/');

Tested it in CMS9, 10 and 11 and all seem to work still. Would you agree?

We would only have to change these lines within PageLayoutHeader and SnippetPreview without the need for the extra utilities and composer packages.

ghost commented 2 years ago

@RinyVT you are right, works fine for me too just change my pl