cross-domain javascript
I am producing a javascript-based widget. Nothing complex just a few document.writes...
When I place it inline in开发者_运维技巧 the page it renders fine in all browsers. When I place it externally and load it via <script src="http://example.com/path/to/site"/>
it fails to render in Firefox and IE but not Chrome.
Anyone know why and a possible workaround?
Maybe you should close it with </script>
instead of XML-style.
精彩评论