Img src is replaced but not background-img
-
Hey,
I have a weird issue, when I activate the plugin, my img url are correctly replaced when it’s an image tag : .
But when I have a div with inline style, the uris are not replaced.
For example, if I execute the following code, just img will be replaced, not the inline style :
<section> <div> @php $bgImage = "background-image:url(". $slider_home[0]->url .")" @endphp <img src="{{ $slider_home[0]->url }}"/> <div style="{!! $bgImage !!}" > </div> </div> </section>
Do you have any explanations ?
I have to admit I don’t understand why …To be sure, I deactivated my cache plugin (wp fatest cache), but anyway, style have the problem.
Thanks,
Viewing 5 replies - 1 through 5 (of 5 total)
Viewing 5 replies - 1 through 5 (of 5 total)
- The topic ‘Img src is replaced but not background-img’ is closed to new replies.