Follow these steps to install this script on your wiki.
http://scripts.mindtouch.com/flickr.xmlRelated Links: DekiScript service, Extension Overview, DekiScript Overview, Extension Demos.
This extension contains functions for embeding tagged pictures from Flickr. This script requires MindTouch Deki 1.8.3 or later.
Functions:
Embed Flicker badge.
Parameters:
| Name | Type | Description |
| tags | str | Comma separated list of tags. (default: "mindtouch") |
Embed Flickr slideshow.
Parameters:
| Name | Type | Description |
| tags | str | (optional) Comma separated list of tags. (default: nil) |
| width | num | (optional) Slideshow width. (default: 450) |
| height | num | (optional) Slideshow height. (default: 400) |
| uri | uri | (optional) URI to user, set, or group page. (default: nil) |
<extension>
<title>MindTouch Flickr Extension</title>
<label>Flickr</label>
<copyright>Copyright (c) 2007, 2008 MindTouch, Inc.</copyright>
<description>This extension contains functions for embeding tagged pictures from Flickr.</description>
<uri.help>http://wiki.developer.mindtouch.com/MindTouch_Deki/Extensions/Flickr</uri.help>
<uri.logo>http://scripts.mindtouch.com/logos/flickr-logo.png</uri.logo>
<namespace>flickr</namespace>
<function>
<name>slideshow</name>
<description>Embed Flickr slideshow.</description>
<param name="tags" type="str" optional="true">Comma separated list of tags. (default: nil)</param>
<param name="width" type="num" optional="true">Slideshow width. (default: 450)</param>
<param name="height" type="num" optional="true">Slideshow height. (default: 400)</param>
<param name="uri" type="uri" optional="true">URI to user, set, or group page. (default: nil)</param>
<return>
<html xmlns:eval="http://mindtouch.com/2007/dekiscript">
<body>
<eval:block value="
var userId = nil;
var groupId = nil;
var setId = nil;
if(args.uri) {
/* uri points to a user account */
var u = uri.parse(args.uri);
if(#u.path >= 2) {
if(u.path[0] == 'photos') {
let userId = web.text(args.uri, './/_:form/_:input[@name=\'w\']/@value');
/* check if uri refers to a set of pictures */
if((#u.path >= 4) && (u.path[2] == 'sets')) {
let setId = u.path[3];
}
} else {
if(u.path[0] == 'groups') {
/* uri points to a group account */
let groupId = web.text(args.uri, './/_:form/_:input[@name=\'w\']/@value');
}
}
}
}">
<iframe
eval:src="uri.build('http://www.flickr.com/slideShow/index.gne', _, { tags: args.tags, user_id: userId, group_id: groupId, set_id: setId })"
eval:width="web.size(args.width ?? 450)"
eval:height="web.size(args.height ?? 400)"
marginwidth="0"
marginheight="0"
hspace="0"
vspace="0"
frameborder="0"
scrolling="no"
/>
</eval:block>
</body>
</html>
</return>
</function>
<function>
<name>badge</name>
<description>Embed Flicker badge.</description>
<param name="tags" type="str">Comma separated list of tags. (default: "mindtouch")</param>
<return>
<html xmlns:eval="http://mindtouch.com/2007/dekiscript">
<body>
<iframe
eval:src="uri.build('http://www.flickr.com/apps/badge/badge_iframe.gne?zg_bg_color=FFFFFF&zg_tag_mode=any', _, { zg_tags: args.tags })"
width="113px"
height="151px"
marginwidth="0"
marginheight="0"
hspace="0"
vspace="0"
frameborder="0"
scrolling="no"
/>
</body>
</html>
</return>
</function>
</extension>
{{ flickr.badge("tag1,tag2") }}
For example, {{ flickr.slideshow("tag1,tag2") }} this appears to default to any images with tag1 or tag2. I would like only images with both tag1&tag2?