netresearch / t3x-rte_ckeditor_image

Image support in CKEditor for the TYPO3 ecosystem
GNU Affero General Public License v3.0
56 stars 65 forks source link

[BUGFIX] fileadmin path without slash won't output in 11LTS #197

Closed jpmschuler closed 2 years ago

jpmschuler commented 2 years ago

After switching to 11LTS I saw an issue:

Some old RTE fields (last change >=5 years) exist which were never properly converted, so using <img src="fileadmin/..."/> (no slash prefix, no data attributes) instead of <img src="/fileadmin/..." data-htmlarea-file-uid=.../>. While in 10LTS they were rendered correctly, in 11LTS they are not processed, keeping the version without a slash, thus not working on subpages.

Diving into the code the SelectImageController as well as the ImageRenderingController use different approaches to manipulate the src. I propose to simplify this. The idea is basically: as long as it is no external URL, it should start with a slash, instead of allowing fileadmin without slash in frontend or force-prefixing a FQDN in backend RTE.

I wonder if that has something to do with https://docs.typo3.org/c/typo3/cms-core/main/en-us/Changelog/11.3/Deprecation-94193-PublicUrlWithRelativePathsInFALAPI.html which was a (IMHO breaking) change from 10LTS to 11LTS concerning the slash prefix for fileadmin.

stephanederer commented 1 year ago

We've got the same issue. Is there a release with this fix available soon? This topic breaks our v11 upgrade.

CybotTM commented 1 year ago

Hi @stephanederer ,

we just released 11.0.6

stephanederer commented 1 year ago

Great, thanks a lot! We've just installed successfully.