
| Vendor | MindTouch |
| Type | Script |
| Categories | Widgets |
| Requires | MindTouch Deki 1.8.3 or later |
| Status | Stable |
| License | Free/Open Source |
| Manifest | http://scripts.mindtouch.com/widgetbox.xml |
Table of Contents
This extension contains functions for embedding WidgetBox widgets.
See also How to add a script, Using the Extension Dialog, Learn about DekiScript, Extensions Directory.
Insert WidgetBox panel.
Parameters:
| Name | Type | Description |
| id | str | Script panel id. |
Insert WidgetBox widget.
Parameters:
| Name | Type | Description |
| id | str | Script widget id. |
<extension>
<title>WidgetBox Extension</title>
<label>WidgetBox</label>
<copyright>Copyright (c) 2006-2009 MindTouch, Inc.</copyright>
<description>This extension contains functions for embedding WidgetBox widgets.</description>
<uri.help>http://wiki.developer.mindtouch.com/MindTouch_Deki/Extensions/WidgetBox</uri.help>
<uri.logo>http://scripts.mindtouch.com/logos/widgetbox-logo.png</uri.logo>
<namespace>widgetbox</namespace>
<function>
<name>panel</name>
<description>Insert WidgetBox panel.</description>
<param name="id" type="str">Script panel id.</param>
<return>
<html xmlns:eval="http://mindtouch.com/2007/dekiscript">
<body>
<script type="text/javascript" eval:src="'http://widgetserver.com/syndication/subscriber/InsertPanel.js?panelId=' .. web.uriencode(args.id)" />
</body>
</html>
</return>
</function>
<function>
<name>widget</name>
<description>Insert WidgetBox widget.</description>
<param name="id" type="str">Script widget id.</param>
<return>
<html xmlns:eval="http://mindtouch.com/2007/dekiscript">
<body>
<script type="text/javascript" eval:src="'http://widgetserver.com/syndication/subscriber/InsertWidget.js?appId=' .. web.uriencode(args.id)" />
</body>
</html>
</return>
</function>
</extension>
To get started, go to Widgetbox.com, find a widget you like, and customize its settings. Once you are done, click on "Get Widget" and a small panel will show up. Click on "Get Widget Code" and copy/paste it into your favorite text editor. The result will look like this:
<script type="text/javascript" src="http://widgetserver.com/syndication/subscriber/InsertPanel.js?panelId=172c1af6-95cd-4e98-86e5-09e6ffd77877"> </script> <noscript>Get great free widgets at <a href="http://www.widgetbox.com">Widgetbox</a>!</noscript>
Now, select the widget code. It starts at ?panelId= and goes to the closing double quotes ("). Use this code when using the widgetbox functions.
| Output | ||
| ||
| ||
|
This is the error code:
line 1, column 56: ":" expected