Make Link Help - Defining Link Types

Make Link comes with three useful default link types to demonstrate a little of what it can do. These basic link types might be enough for you. However if you need more control over what types of links you generate, you can customise the set of link types offered to you. This document is a short description of what you need to know to create your own link types for Make Link.

Contexts

Make Link creates links differently depending on the context in which it is invoked, i.e., depending on what you right-click on to get the Make Link menu. The three contexts are link, selection, and page.

Link
When you select a Make Link option after right-clicking on a link it will be invoked in link mode.
Selection
When you select a Make Link option after right-clicking on some selected (highlighted) text it will be invoked in selection mode.
Page
When you select a Make Link option by any other method it will be invoked in page mode.

Variables

Make Link recognises a set of variables which represent the various data related to links. For example the variable %url% represents the URL (web address) of a link. When you define the format for a link type in Make Link you do so by combining normal text with these variables. For example the Plain Text link type (one of Make Link's defaults) has the format “%text% (%url%)”. Make Link interprets this format by replacing %text% with the actual text of the link and %url% with the URL of the link.

The contents of some variables depend on the context in which it was invoked. The variables are as follows:

%text%
The text of the link.
In link context: the text of the original link.
In selection context: the selected text.
In page context: the page title element (the text that appears in the title-bar).
%text_n%,%text_br%
The text of the link.
In selection context: the selected text, in which "\n" is copied as it is(%text_n%) or is replaced by "<br />\n" (%text_br%).
In other contexts: same value as %text%.
%url%
The URL of the link.
In link context: the href attribute of the original link (the URL of the target page).
In page or selection context: the URL of the current page.
%title%
The link title.
In link context: the title attribute of the original link (the tool-tip text).
In selection context: the page title element (the text that appears in the title-bar).
In page context: the content attribute of any meta element with a name of “description”.
%input%
You will be prompted to provide the text to replace this variable each time you choose a link type with this variable in it.
%imgurl%
If you right-click on an image, this variable will contain the URL of that image. Otherwise it will be blank.
%tinyurl% (experimental)
Uses the durl.us or TinyURL services to generate a shortened alias for the URL represented by %url%. This is an experimental feature which may display bugs, including momentary interface hangs and silent failure (i.e., it may fail to copy anything to the clipboard and fail to notify you). You can verify that it has worked either by checking the contents of the clipboard before invoking Make Link (therefore letting you know if the new contents are different) or by verifying the short URL after it is generated by visiting it. This feature will often work on a second attempt if it has failed initially.