开发者

Google Gadgets and external scripts

开发者 https://www.devze.com 2023-01-03 02:36 出处:网络
I\'m trying to create my first custom Google Gadget to be used privately in my company\'s Google Sites intranet. Ideally I\'d like to just show a thumbnail that the user can click that will open a mod

I'm trying to create my first custom Google Gadget to be used privately in my company's Google Sites intranet. Ideally I'd like to just show a thumbnail that the user can click that will open a modal window with the full video. This requires my including a couple of small JS libraries in my widget.

For my widget I created this XML:

<?xml version="1.0" encoding="UTF-8"?>
<Module>
    <ModulePrefs title="Video Demos" />开发者_Go百科
    <Content view="url" 
        href="http://www.website.com/_gadgets/video.php">
    </Content>
</Module>

The "video.php" page has simple HTML on it and includes two JS files for the modal window using but doesn't work.

Are you not able to include external scripts like this? If not, what are my options here?


The content tag is wrong. You must set the "type" attribute as "url":

<?xml version="1.0" encoding="UTF-8"?>
<Module>
    <ModulePrefs title="Video Demos" />
    <Content type="url" 
        href="http://www.website.com/_gadgets/video.php">
    </Content>
</Module>

[]s

0

精彩评论

暂无评论...
验证码 换一张
取 消