Template:Location map many: Difference between revisions

From Zoophilia Wiki
Jump to navigationJump to search
meta>Droll
Undid revision 374514117 by Testter (talk) added no new functionality and transcluded a template that is being considered for deletion
meta>Plastikspork
Simplify code base to call Template:Location map~ and Template:Location map+. This was the easiest way to fix this template after changes to Template:Location map China, ...
Line 1: Line 1:
<includeonly><!--
<includeonly>{{Location map+
-- Template for image with markers/labels (see bottom "NOTES")
|{{{1|World}}}
--
|width={{{width|}}}
--  This template overlays 9 specified markers/labels on a given
|float={{{float|}}}
--  map (in the manner of "Template:Location_map") but also
|alt={{{alt|}}}
--  checks each latitude/longitude against border limits.
|border={{{border|}}}
--
|caption={{{caption|}}}
--  Warning: Code multi-nested 18 levels across 1080+ lines.
|label={{{label1|{{{label|}}} }}}
--  Warning: {{Might}}{{{appear|become}}}{{unreadable}}?
|AlternativeMap={{{AlternativeMap|}}}
--  Warning: This template might exceed wiki-template resources.
|places= {{#if:{{{lat1|{{{lat|}}} }}}{{{lat1_deg|{{{lat_deg|}}} }}}
--  Warning: Adding spaces can kill results.
    |{{Location map~|{{{1|World}}}|lat=
----------------------------------------------- Begin box division
--><div style="width: {{#expr: {{{width|240}}} + 2 }}px; {{#if: {{{caption|}}}
  | padding: 3px; border: 1px solid {{#if: {{{border|}}}
    | {{{border|none}}}
    | #CCCCCC
  }}; margin: 3px;
}} float:{{#switch:{{{float|}}}
|  "center"=none | center=none  | "left"=left  | left=left
|  "right"=right | right=right  | "none"=none  | none=none
|right}}; clear:{{#switch:{{{float|}}}
|  "center"=both | center=both | "left"=left | left=left
|  "right"=right | right=right | "none"=none | none=none
|right}}; {{#if: {{{caption|}}}
  | ;background:#F9F9F9"|"
  }}><!--
---------------------------------------------- Begin Map division
--><div style="position: relative;{{#ifeq: {{{border|}}} | none |
  |border: 1px solid {{#if: {{{border|}}}
    | {{{border}}}
    | {{#if:{{{caption|}}}|#CCCCCC|none}}
  }};
}} padding: 0px; width: {{{width|240}}}px">[[image:{{#if: {{{AlternativeMap|}}}
  | {{{AlternativeMap}}}
  | {{Location map {{{1}}}|image}} }}|{{{width|240}}}px|{{#if: {{{label|}}}
    | {{{label}}}
    | {{PAGENAME}}
  }}<!-- endif label--> ({{Location map {{{1}}}|name}})]]<br /><!--
================================================= Marker/Label #1
-->{{#if: {{{lat|{{{lat_deg|}}} }}} | <!--
  --then latitude-1 exists --------------- Verify lat./longitude
-->{{
#ifexpr:{{{lat|{{{lat_deg|}}}}}}<{{Location map {{{1}}}|bottom}}
  |<!--then-->Latitude#1 ({{{lat|{{{lat_deg|}}}}}}) < map<!--
  --> min({{#expr:{{Location map {{{1}}}|bottom}} round 2}}).| }}
{{#ifexpr: {{{lat|{{{lat_deg|}}}}}} > {{Location map {{{1}}}|top}}
  |<!--then-->Latitude#1 ({{{lat|{{{lat_deg|}}}}}}) > map<!--
      --> max({{#expr:{{
{{Documentation}}
{{Documentation}}
<!-- PLEASE ADD THIS TEMPLATE'S CATEGORIES AND INTERWIKIS TO THE /doc SUBPAGE, THANKS -->
<!-- PLEASE ADD THIS TEMPLATE'S CATEGORIES AND INTERWIKIS TO THE /doc SUBPAGE, THANKS -->
{{DEFAULTSORT:{{PAGENAME}}}}
</noinclude>
</noinclude>

Revision as of 15:47, 31 July 2010