-
Re: Can we link to an external stylesheet inside of an HTML widget on Jive Cloud?
David Bastedo Jan 7, 2015 9:07 AM (in response to rwhitworth)I'm following up on this support discussion, as it looks like this issue was handled in a separate support case. I wanted to post back here in case anyone else in the community has the same question.
Widgets cannot use global CSS or JavaScript code (see HTML and Formatted Text Widgets) - This means that the first two examples are the expected behavior of the system.
Managing HTML Widget Security
To ensure security and prevent problems that can corrupt your pages and keep them from loading, any HTML widget code that calls a <script> tag will be contained in an isolated iFrame. This is known as "safe mode." If you want to include CSS or other styling in the widget, you can include it in the same location as your HTML code. Isolation of the HTML widget also means that the widget can't borrow JavaScript from the Overview page, and that visual components cannot extend beyond the perimeter of the iframe. Simple HTML, JavaScript, and CSS continue to be supported.
In safe mode, you can still call the assets associated with the core Jive installation as follows: <script src="/resources/scripts/jquery/jquery.js"></script><link rel="stylesheet" href="/styles/jive.css" media="all">