siteorigin / so-widgets-bundle

The SiteOrigin Widgets Bundle gives you all the elements you need to build modern, responsive, and engaging website pages. Using the Widgets Bundle, you can quickly and effortlessly add buttons, sliders, heroes, maps, images, carousels, features, icons, and so much more.
https://siteorigin.com/widgets-bundle/
94 stars 66 forks source link

Headline: esc_html_e($tag) in template causes TranslatePress to break layout #1965

Closed sitoexpress closed 4 months ago

sitoexpress commented 4 months ago

While setting up a multilingual website moving form WPML to TranslatePress, everything was almost working fine, but the Headline widget messing up the page HTML in TranslatePress translations.

After some digging, I've noticed that esc_html_e($tag) in tpl/default.php of the Headline widget could be switched with echo esc_attr($tag), since there's no need to escape any actual special html character such as <, keeping things safe while making TranslatePress work fine with headline text translation.

AlexGStapleton commented 4 months ago

Hi @sitoexpress,

Thank you for reporting this. I've corrected this issue in https://github.com/siteorigin/so-widgets-bundle/pull/1968 and it'll be included in a future SiteOrigin Widgets Bundle update. Thanks again! :)

Kind regards, Alex