My view send to my template one object with this value:
http://dominio/rota/id/original/(nome)8.jpg
In my templete I have:
<div style="background-image: url( ' {{ obj.url }} ' )"></div>
When my template is rendered it looks like this:
background-image: url(' http://dominio/rota/id/original/(nome)8.jpg ' );
Error:
Invalid property value
This happens because inside the URL there is a ")" that encloses the value of the url ()
How can I solve this?
I tried the following combinations in the template, without success:
<div style="background-image: url( {{ obj.url }} )"></div>
<div style='background-image: url( " {{ obj.url }} " )'></div>
<div style="background-image: url( ' {{ obj.url }} ' )"></div>
<div style='background-image: url( {{ obj.url }} )'></div>