Ticket #13511 (confirmed Bug)
Diazo external script tag src breaks rules.xml
Reported by: | danboggins | Owned by: | |
---|---|---|---|
Priority: | minor | Milestone: | 4.x |
Component: | Diazo (plone.app.theming) | Version: | 4.2 |
Keywords: | rules, script, external | Cc: |
Description
The use case for this is creating a custom Google Map (you are required to include their JS library located on Googles servers)
When trying to append a <script> tag to document <head> with an external src via rules.xml, the entire Diazo theme breaks. (the reason for this is the map only appears on one page, in order to keep things speedy I'm only applying the JS to the pages containing the map div)
Rule EG:
<rules css:if-content="#map"> <append theme="/html/body"> <script type="text/javascript" src="https://maps.googleapis.com/maps/api/js?key=XXXX&sensor=false"></script> </append> </rules>
I have tried removing the https from the script tag thinking it might be that, but unfortunately it still proves to break the theme.
Change History
Note: See
TracTickets for help on using
tickets.