Version 1.07 breaks templating with HTML
See original GitHub issueThis change in Version 1.07
var formatted = this.display(selection, $rendered);
to
var formatted = Utils.entityDecode(this.display(selection, $rendered));
strips any HTML from the rendered selected item.
This stops you from being able to use html for styling of the selected item, via templating as per the documentation for select2: https://select2.org/selections.
For this reason I have had to dequeue selectWoo in Wordpress and load select2 itself.
Sorry for lack of example - but it is self-evident.
How big a security issue is the un-escaped HTML?
Issue Analytics
- State:
- Created 3 years ago
- Reactions:2
- Comments:5
Top Results From Across the Web
HTML::Template::Compiled - MetaCPAN
It's possible since version 0.69 to inherit from HTML::Template::Compiled. It's just not documented, and internal method names might change in the near future....
Read more >Markdeep - Casual Effects
Added corporate API and whitepaper templates. 2019-11-29 Version 1.07. Improved printing quality. Added support for escaped backticks \` to prevent inline code ...
Read more >HTML::Template::Compiled(3pm) — libhtml-template-compiled-perl ...
HTML ::Template::Compiled is a template system which can be used for HTML::Template templates with almost the same API. It offers more flexible template...
Read more >Problem with HTML Template pages breaking when they are ...
I moved some html files that were created from the Daylight HTML Template pages to a new folder in Manage Files and it...
Read more >transform - CSS: Cascading Style Sheets - MDN Web Docs
The transform CSS property lets you rotate, scale, skew, or translate an element. It modifies the coordinate space of the CSS visual ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
The issue is still causing problems today.
Hello @fabianmarz,
Thanks for the feedback!
I don’t modify the core files since I simply disable the script enqueue to let ACF use the correct select2 JS library instead, as explained in my comment.
I posted the JS code here to explain where the problem come from, so anyone can test the fix with dist files. I already ran multiple version compare on this library and I don’t have the time dig further to point you the exact location of those lines in the source.
So I will let core developers decide if this fix is correct or not. I’m sure they know better where those lines are in source files anyway.
Thanks for the thumbs down!
Have a nice day.
Regards.