Expand my Community achievements bar.

Enhance your AEM Assets & Boost Your Development: [AEM Gems | June 19, 2024] Improving the Developer Experience with New APIs and Events

Is there a way to rewrite urls within style html attribute using static reference rewriter?

Avatar

Level 1

Hi

Is there a way to rewrite the static urls within style html attribute using ACS AEM Commons Static Reference rewriter (detailed here)?

Sample code: <div style="background-image: url('/content/dam/*****.jpg');"/>

Thanks

2 Replies

Avatar

Level 10

The docs on that page seems to indicate you can do this task.

Avatar

Level 1

No, it didn't work. I tried adding div:style to the config, but it didn't rewrite the url within background-image.