Template:Maplink

From AkanaWiki
Jump to navigation Jump to search

Usage notes

A template for creating clickable links from names on a map. To be placed inside a <div> tag, which must contain the style definition style="position: relative" and the attribute class="mapdiv". The first line within the tag should contain the link to the map image; subsequent lines can hold different instances of the {{Maplink}} template.

The template accepts 4 variables:

  1. link title
  2. Y position in px (distance from top of image)
  3. X position in px (distance from right of image)
  4. optional: link target (if this is not specified, #1 is used)

Short examples

{{maplink|Lasomo|50|100}}

places a link to [[Lasomo]] 50px from the top and 100px from the right edge of the image.

{{maplink|Lasomo|50|100|Axôltseubeu}}

places a link that looks exactly the same, but leads to [[Axôltseubeu]] instead - as if you had written [[Axôltseubeu|Lasomo]] in normal wikitext.

Full example

<div style="position: relative" class="mapdiv">
[[Image:Kechaena-blank.png|thumb|right|600px|Map of Peilaš]]
{{maplink|Siixtaguna|120|120}}
{{maplink|Lotoka|180|210}}
{{maplink|Huyfárah|175|290}}
{{maplink|Kasca|220|320}}
{{maplink|Lasomo|190|350}}
{{maplink|Rathedān|230|380}}
</div>

gives