version=pmwiki-2.2.5 ordered=1 urlencoded=1 agent=Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET CLR 1.0.3705; .NET CLR 1.1.4322; .NET CLR 2.0.50727) author=SchreyP charset=ISO-8859-1 csum=improve former change, show InterMaps by example host=81.240.23.93 name=PmWiki.InterMap rev=47 targets=PmWiki.WikiWikiWeb,Site.InterMap,PmWiki.CustomInterMap text=(:Summary: Interwiki links definition and use:)%0a(:Audience: author (intermediate) :)%0a%0aThe InterMap (also called InterWiki in some other wikis) is a system for defining links between [[WikiWikiWeb]] sites that was first developed by UseMod and Meatball (see UseMod:InterWiki and Meatball:InterWiki). The method is to use a word that stands for a path that is defined. InterMap links have the form [@MapPrefix:PagePath@], where the host prefix is converted to a partial URL based on entries in the site's ''intermap.txt'' and ''localmap.txt'' files.%0a%0a[[#custominclude]]%0aThe default ''intermap.txt'' distributed with PmWiki (in the ''scripts/'' directory) includes the following InterMap entries:%0a>>pre%3c%3c%0a PmWiki: http://www.pmwiki.org/wiki/PmWiki/ %0a Cookbook: http://www.pmwiki.org/wiki/Cookbook/ %0a Wiki: http://www.c2.com/cgi/wiki? %0a UseMod: http://www.usemod.com/cgi-bin/wiki.pl? %0a Meatball: http://www.usemod.com/cgi-bin/mb.pl? %0a Wikipedia: http://www.wikipedia.com/wiki/ %0a PITS: http://www.pmwiki.org/PITS/ %0a Path:%0a>>%3c%3c%0a%0a(:if exists {$SiteGroup}.InterMap:)%0a[[{$SiteGroup}.InterMap]] includes the following entries:%0a(:include {$SiteGroup}.InterMap#include#includeend:)%0a(:else:)%0aYou can map your own prefixes in your local page [[{$SiteGroup}.InterMap]].%0a(:ifend:)%0a[[#customincludeend]]%0a%0aThus, "PmWiki:Variables" becomes "http://www.pmwiki.org/wiki/PmWiki/" + "Variables," a link to the [[PmWiki.Variables->http://www.pmwiki.org/wiki/PmWiki/Variables]] page on the official PmWiki web site, Wiki:FrontPage is a link to the front page of the first WikiWikiWeb, and Wikipedia:Stonehenge takes you to the Wikipedia article about the famous megaliths in England. %0a%0aLike other links, you can use the double-bracket syntax to get different link text:%0a(:markup class=horiz:)%0a* [[Meatball:StartingPoints | starting points]] over at Meatball%0a* [[starting points -> Meatball:StartingPoints]] over at Meatball%0a(:markupend:)%0a%0aIf you want to link just to what the intermap says (e.g. http://www.wikipedia.com/wiki/ for Wikipedia), then do [@[[Wikipedia:. | Wikipedia's main page]]@], which produces [[Wikipedia:. | Wikipedia's main page]]. Note the . (period) after the Map: reference.%0a%0a[[#path]]%0aThe special [@Path:@] InterMap entry can be used to create "[[Cookbook:RelativeUrls|relative urls]]" in [[Cookbook:RelativeLinks|links]].%0a%0aThe actual set of InterMap links at any site is defined by the site administrator via the [[Site.InterMap]] page and the ''local/localmap.txt'' file; for more details, see [[PmWiki.CustomInterMap]]s.%0a time=1253825216