Comments (15)
we should find a universal solution.
That would be an impertinence for every field and for every extension to add.
@mbrodala what do you mean?
from t3x-rte_ckeditor_image.
Hi @mbrodala,
thanks for your hint.
Not simple to count it down again after removing an image.
Feel free to add a pull request.
from t3x-rte_ckeditor_image.
In fact we have ported the soft reference index from sgalinski/tinymce4-rte
and it's working just fine. Adding images (even resized) increases the reference count, removing them again decreases it. The DataHandler
takes care of all this but it needs a hint, how many references are in a blob of text.
We'll test this a little longer and if it works fine, I'll add a PR with this. :-)
from t3x-rte_ckeditor_image.
Sounds good. Would be very nice.
from t3x-rte_ckeditor_image.
@mbrodala,
any news on this?
from t3x-rte_ckeditor_image.
I was off for vacation in the last 2 weeks. Our fix seems to work fine, I just need some time to turn it into a PR. I try to do this this week.
from t3x-rte_ckeditor_image.
Hey @mbrodala, I'm still interested!
from t3x-rte_ckeditor_image.
Hi @mbrodala,
I did some cleanups and merged your changes into master via branch issue-45.
I squashed the commits to not have cleanup commits in master.
Please check the current master.
Thanks for your help!
from t3x-rte_ckeditor_image.
Thanks a lot, looking forward to the next release. :-)
from t3x-rte_ckeditor_image.
For the reference: 8005c8b
from t3x-rte_ckeditor_image.
What if the editor is outside of ['tt_content'] ['columns'] ['bodytext']?
New field? News plugin? Own extension?
from t3x-rte_ckeditor_image.
@prdt3e See the related change, you'll need to add a small TCA overrides snippet for your field.
from t3x-rte_ckeditor_image.
The solution can be found here with a loop.
It would then be all fields in tt_content covered.
https://github.com/FriendsOfTYPO3/rtehtmlarea/blob/master/Configuration/TCA/Overrides/tt_content.php
But I'm not happy.
from t3x-rte_ckeditor_image.
What is the current status on this?
I tested that a sys_refindex entry gets created when inserting an image in an RTE-field (tt_content.bodytext). This is the case for 9.0.4, but not for 9.0.3 so this looks good.
Is this now fixed in general or does this only work now for some specific fields? (In the patch it looks like the TCA changes are only made for tt_content.bodytext.)
Will updating the reference index also add references for previously inserted images?
from t3x-rte_ckeditor_image.
Can you please add the "bug" label? This is a bug. If the reference index is not updated, the references will not be shown in the file list which may result in files being removed (by unsuspecting editors) even though they are still being used.
Current status: Reference index entry is not created with latest master:
- rte_ckeditor_image: dev-master
- TYPO3 11.5.25 or dev-11.5
I noticed that what is returned by RteImageSoftReferenceParser::findImageTags is probably wrong.
return [
'content' => implode('', $this->splitContentTags),
'elements' => $images,
];
should be:
return $images;
Comparing what is passed to (the core) SoftReferenceParserResult::create function with an rte image tag, the result is wrapped in an extra content / elements array:
- with rte image tag
$elements is
content : "<p><img ---"
elements:
1:
matchString":"<img ..."
subst:
type: "db"
recordRef: "sys_file:17804",
tokenID: "f6f3a30214c2f46e38d28c50e19e65c8"
tokenValue: "17804"
- with file link, it looks more like this:
1:
matchString":"<a href= ..."
subst:
type: "db"
recordRef: "sys_file:17804",
tokenID: "f6f3a30214c2f46e38d28c50e19e65c8"
tokenValue: "file:17804"
from t3x-rte_ckeditor_image.
Related Issues (20)
- If the image is a SVG, the attribut loading lazy is not added to the image tag
- 'class' attribute ignored HOT 5
- Image alignment HOT 2
- Regression: "Call to a member function count() on null" HOT 2
- Typo3 v12.4 / PHP 8.2 - Extension not working HOT 6
- Inline Images HOT 11
- TYPO3 12.4.11 Not working with News
- Regression for #199 HOT 1
- StylesSet for images HOT 2
- lazyloading - wrong TS
- PHP Warning: Undefined variable $isSavingOfMailAllowed HOT 1
- In the failing tests / github "jobs" for v13 is still `typo3/cms-recordlist` mentioned, that was already removed in v12.
- Adding the plugin in a TYPO3 12 instance HOT 2
- No processed files are generated (backend and frontend) HOT 7
- Width of imgages in CKeditor after recreation (deletion of fileadmin/_processed) is always 300 HOT 1
- Linking an image not working
- Documentation is outdatet for V12 HOT 1
- Image selector not working with non-admin user HOT 3
- Images are not processed and unwanted attributes HOT 2
- I think the package name 'cms_rte_ckeditor' in https://github.com/netresearch/t3x-rte_ckeditor_image/blob/main/ext_emconf.php is wrong! Please fix it! HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from t3x-rte_ckeditor_image.