This shows you the differences between two versions of the page.
|
api [2010/01/25 02:16] teamustart |
api [2010/02/13 15:12] (current) teamustart |
||
|---|---|---|---|
| Line 44: | Line 44: | ||
| ===== Main Object : widget ===== | ===== Main Object : widget ===== | ||
| + | |||
| + | == HTML constructor == | ||
| + | * widget.setOptions(html) : changes the HTML of the options section | ||
| + | |||
| + | * widget.setContent(html) : changes the HTML of the widget body | ||
| + | |||
| + | * widget.setTitle(title) : change the title of the widget | ||
| + | |||
| + | * widget.setUnread(unread) : set number of unread items in this widget | ||
| + | |||
| + | * widget.select(selector,options) : select DOM objects according to the css selector (eg div#my_section) , return an aray | ||
| + | |||
| + | == Preferences == | ||
| + | * widget.setPref(name,value) : store a variable | ||
| + | * widget.getPref(name,value) : get a stored variable | ||
| + | |||
| + | == Ajax == | ||
| + | * widget.GetFeed(url,callback) : AJAX get the feed and return the parsed feed in callback function | ||
| + | * widget.GetUrl(url,callback) : AJAX get the url and return the text in callback function | ||