September 8, 2008

Extension of the Week: TinyURL

The extension I’m focusing on this week is TinyURL which generates a shorten url for your MindTouch TinyURL Deki pages. This is beneficial when you have a deep hierarchy and want a quick url to send to people. There is something unique about this extension, you don’t have to install anything. This extension was created using DekiScript.

To invoke the extension, paste the following code in a MindTouch Deki page:

{{ web.link(web.text(uri.build("http://tinyurl.com/api-create.php", _,
{  url: page.uri }))) }}

It will turn this:
http://wiki.developer.mindtouch.com/DekiScript/FAQ/How_do_I…_Generate_a_TinyURL_for_my_pages_automatically%3f

into this:

http://tinyurl.com/58j9ea

This script is dynamic, so it will create a new url for each page it is pasted on without having to change anything.

I encourage you to read more about DekiScript and how it can enhance your Deki install.

If you have any questions please feel free to contact us or post a comment.