[
https://issues.apache.org/jira/browse/SLING-6490?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15842805#comment-15842805
]
Vlad Bailescu commented on SLING-6490:
--------------------------------------
For more clarity: there is no HTL context at the moment that can handle entire
CSS declarations. Same goes for JavaScript code and this is by design of the
language/contexts so that HTL expression are only used in pin-point locations,
instead of injecting large CSS/JS blocks of code. This keeps CSS and JS close
to the HTML template.
> Sightly doesn't render valid style attribute-value
> --------------------------------------------------
>
> Key: SLING-6490
> URL: https://issues.apache.org/jira/browse/SLING-6490
> Project: Sling
> Issue Type: Bug
> Components: Scripting
> Reporter: Feike Visser
> Labels: Sightly
>
> I have the following piece of Java:
> {code}
> public class Style {
> public String style = "background-image: url('/path/to/image.jpg');";
> }
> {code}
> I can't get this value printed unless I use @ context = 'unsafe'
> {code}
> <div class="container" data-sly-use.fv="Style" style="${ fv.style @
> context='styleToken' }">
>
> </div>
> {code}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)