Table of contents
  1. 1. Usage
  2. 2. Demo
  3. 3. Template Source Code

Quite often I find myself wanting to showcase a website as a thumbnail. Then I found WebSnapr which does exactly that.  A few moments later, I created a wiki template that makes it super easy to use WebSnaper inside wiki pages.  The wiki template uses the new DekiScript XML features introduced in 9.02.  The MindTouch In the Wild has been updated to use this new template as well.

Usage

To embed a website thumbnail with the template, just embed the following code snippet:

{{ SitePreview('http://cnn.com', 'CNN.com') }}

Demo

 

Template Source Code

var url = $0 ?? $uri ?? '';
if(#url != 0) {
    var title = $1 ?? $title ?? url;
    <div style="width: 225px;">
        <div align="center">
            <div style="border: 1px solid black; width: 202px">web.link(url, web.image('http://images.websnapr.com/?size=s&nocache=42' & { url: url }));<br/></div>
            <small>web.link(url, title);</small>
        </div>
    </div>
}
Tag page (Edit tags)
You must login to post a comment.