Module:Location map/data/USA Alaska/doc
![]() | This is a documentation subpage for Module:Location map/data/USA Alaska. It may contain usage information, categories and other content that is not part of the original module page. |
![]() | This is a documentation subpage for Module:Location map/data/USA Alaska. It may contain usage information, categories and other content that is not part of the original module page. |
Template:Location map USA Alaska is a location map definition used to overlay markers and labels on a map of Alaska. It is used by "Template:Location map" when invoked with parameter "USA Alaska": {{Location map | USA Alaska | ...}}
. The markers are placed by latitude and longitude coordinates on the default map or a similar map image.
[[Image:Template:Location map/data/USA Alaska|left|thumb|200px|Location map for Template:Location map/data/USA Alaska]]
Map parameters | ||
---|---|---|
name | Template:Location map/data/USA Alaska | name used in default map caption |
image | Template:Location map/data/USA Alaska | file name of map image, without "Image:" or "File:" |
x | Template:Location map/data/USA Alaska | an expression which returns 0 for the left edge of the map, and 100 for the right edge of the map, where {{{2}}} and {{{3}}} are the degrees latitude and longitude respectively. |
y | Template:Location map/data/USA Alaska | an expression which returns 0 for the top edge of the map, and 100 for the bottom edge of the map, where {{{2}}} and {{{3}}} are the degrees latitude and longitude respectively. |
Usage
For a description of the parameters, see {{Location map}} and {{Location map many}}.
Location map: Eastern hemisphere, Deg/Min/Sec coordinates
{{Location map | USA Alaska | width = 200 | float = right | label = Attu Island | position = right | caption = Location of [[Attu Island]] in Alaska | lat_deg = 52 | lat_min= 54 | lat_sec = 09 | lat_dir = N | lon_deg = 172 | lon_min= 54 | lon_sec = 34 | lon_dir = E }}
Location map: Eastern hemisphere, Decimal coordinates
{{Location map | USA Alaska | width = 200 | float = right | label = Attu Island | position = right | caption = Location of [[Attu Island]] in Alaska | lat = 52.9025 | long = 172.909444 }}
Location map: Western hemisphere, Deg/Min/Sec coordinates
{{Location map | USA Alaska | width = 200 | float = right | label = Ketchikan | position = left | caption = Location of [[Ketchikan]] in Alaska | lat_deg = 55 | lat_min= 21 | lat_sec = 00 | lat_dir = N | lon_deg = 131 | lon_min= 40 | lon_sec = 24 | lon_dir = W }}
Location map: Western hemisphere, Decimal coordinates
{{Location map | USA Alaska | width = 200 | float = right | label = Ketchikan | position = left | caption = Location of [[Ketchikan]] in Alaska | lat = 55.35 | long = -131.673333 }}
Location map many: Deg/Min/Sec coordinates
{{Location map many | USA Alaska | float = right | width = 200 | caption = [[Attu Island]] and [[Ketchikan]] in Alaska | label = Attu Island | label_size = 90 | pos = right | lat_deg = 52 | lat_min= 54 | lat_sec = 09 | lat_dir = N | lon_deg = 172 | lon_min= 54 | lon_sec = 34 | lon_dir = E | label2 = Ketchikan | label2_size = 90 | pos2 = left | lat2_deg = 55 | lat2_min= 21 | lat2_sec = 00 | lat2_dir = N | lon2_deg = 131 | lon2_min= 40 | lon2_sec = 24 | lon2_dir = W }}
Location map many: Decimal coordinates
{{Location map many | USA Alaska | float = right | width = 200 | caption = [[Attu Island]] and [[Ketchikan]] in Alaska | label = Attu Island | label_size = 90 | pos = right | lat = 52.9025 | long = 172.909444 | label2 = Ketchikan | label2_size = 90 | pos2 = left | lat2 = 55.35 | long2 = -131.673333 }}
As shown above, the current implementation of Template:Location map many does not properly display the marker when given a negative longitude (western hemisphere). One workaround is to include the parameter lon_dir (or lon2_dir, lon3_dir, etc.): Lua error in Module:Location_map at line 391: A hemisphere can only be provided with DMS degrees for longitude.
{{Location map many | USA Alaska | float = right | width = 200 | caption = [[Attu Island]] and [[Ketchikan]] in Alaska | label = Attu Island | label_size = 90 | pos = right | lat = 52.9025 | long = 172.909444 | label2 = Ketchikan | label2_size = 90 | pos2 = left | lat2 = 55.35 | long2 = -131.673333 | lon2_dir = W }}