-
Notifications
You must be signed in to change notification settings - Fork 64
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
Using images not from the file system #156
Comments
@fssuter Can you add your version numbers (TYPO3 and rte_ckeditor_image)? I assume, this issue still exists but some things have changed between TYPO3 versions. |
I'm using TYPO3 11.5.24 and rte_ckeditor_image version 11.0.6 Indeed there seems to have been a lot of changes since then... |
shouldn't the storage be responsible to deliver the domain? |
That's not the issue (or I misunderstand your question). In the case of the S3 driver that I am using, it provides correct, fully qualified URIs to the images in the "publicUrl" property, but that is then "truncated" in the extension's JS. |
ok, then I misunderstood the problem. |
@fsuter does the problem still exist ? |
Sorry for not following up, I only recently got to putting the web site where I had the problem through a major update. The problem does not exist anymore, although the code that originally caused the problem is still there. So I don't really understand why, but it works. |
Actually the problem still exists. I'm not sure how I missed it. The fix I proposed is still valid as far as I'm concerned, but I don't know if it may have side effects. One sure thing is that this is the only use of function At least, images from a local storage like "fileadmin" still work fine after the change. |
When using images from a FAL storage other than the local file system, the images will have public URLs which are absolute URLs. In file
rte-ckeditor-image/Resources/Public/JavaScript/Plugins/typo3image.js
, when an image in inserted, the protocol/domain part is stripped with methodurlToRelative
which is okay when the file is local, but definitely not when the file is on some remote server (e.g. a S3 server).I'm not sure how to fix this at best, as there could be side effects. In my case, since all files are on a S3 server, I just patched the JS to change line 267 from:
src: urlToRelative(getImg.url),
to
src: getImg.url,
The text was updated successfully, but these errors were encountered: