Template:Location map/Creating a new map definition

Template page

If you have any questions about how to use the wiki, please go to the discussion section for this page to ask a question.

Submit an Error Report:

Go to Errors and follow the instructions there.

Browsing www.ooda.wiki

Reporting Errors

The Errors page details the steps for reporting errors on the site, but generally adding a discussion to the page where the error occurred, adding a discussion to the errors discussion page, and/or sending an email to the relevant address (listed on the Errors Page)

Searching www.ooda.wiki

Rather than a search bar, www.ooda.wiki uses the Citizen Skin's built in search. This can be activated either by pressing on the magnifying glass button on the side of any web page, or by pressing "/".

Contributing to www.ooda.wiki

Create an Account Or Logging In

The icon on the bottom left under the gear is the user icon. Click it in order to access the Log in or Create Account option.

In the bottom left corner of the screen click on the icon, and then click either create account if you have not made an account yet, or log in if you have. It is recommended that those of you who wish to join this endeavor create a dedicated email account for free at Skiff and use that email address when signing up for OODAwiki.

Join a Contubernium

Edit an Existing Wiki Page:

The button to enter Visual Editing mode is at the top-right hand corner of any wiki page you can edit.

While Logged in, Click on the top right on the edit icon. This will take you into the Visual Editing mode which, once you click on the text on the page allows you to type any text, change text variables, add citations or insert content using the Visual Editing menu bar.

Make sure to hit the Save changes... button located nearby where the edit icon was to enter visual editing mode, and then add a brief description of the changes in order to save any edits.

The icon to the right of the regular edit icon is the "source" edit which allows for more flexibility but is less human readable. However, switching from visual editing to source editing deletes all unsaved text changes, so proceed carefully.

Headings and Table of Contents

Clicking on the Toolbar here will allow you to turn a line into a Heading

While in Visual Editing mode, up in the menu bar, you should see an option titled something like "Paragraph, Heading, Sub-Heading" or similar. Most of the time, your editing will be done in paragraph mode, which is the default and regular text mode. Changing any section of text to one of the sub-headings will lead to it appearing in the table of contents to the right, once sufficient headings and subheadings are created. The table of contents automatically sorts the headings into a functional list, with subheading appearing as indented sections of the hierarchy. Avoid making any extremely large lines of text as a Heading or Sub-Heading, as this reduces the functionality of the table of Contents.

Visual Editing Options menu

The Visual Editing Options Menu is part of the right-justified portion of the toolbar. Note the save changes button to the right of the edit icon as well.

The visual editing options menu allows for editing a page by adding categories, investigating and adding templates, to find and replace specific words, and other useful options. In particular it is recommended to add relevant categories, such as "Patterns of Conflict" to any Patterns of Conflict slide pages to keep the wiki navigable.

Upload an Image:

Insert an image into a Wiki Page:

Create a New Page:

If you go to a url in this wiki that is valid, in the form of www.ooda.wiki/wiki/__new_page_name_here, you can create a new page after adding any amount of content in the visual editor and passing a query captcha. For example, to create the Patterns of Conflict Slide 100 page, you would first go to the url www.ooda.wiki/wiki/Patterns_of_Conflict_Slide_100, and a small amount of content, save changes and then the page will be created.

Create, Prepare or Edit A Day's Featured Article

Similar to the process for creating a new page, you need to create or go to the page of the featured day. For example the page for the day of April 16 2023 was OODA Wiki:Today's featured article/April 16, 2023. An example of an upcoming day without a page would be the page for May 27 of 2023 which will be OODA Wiki:Today's featured article/May 27, 2023. On the relevant day, this page is automatically grabbed on the front page using the Ordinary Date Time Magic Words which pulls all of the text of the page under the section on the main page labeled "Today's Featured Article".

When preparing a featured article for a specific day, make sure that there is a link to the article featured in the Today's featured article page for the day, and Do Not Copy the Entire Featured Article, instead only put in the today's featured article page either a quick summary, or the top few lines of the featured article page.

The Relevant Code for a Sidebar Template

Editing a Sidebar List Template

To edit a sidebar list template, you must first figure out what the actual template is. The fastest way to get to the template edit screen for sidebar lists is by clicking on the small "E" at the bottom right hand corner of the sidebar.

The slower way is to find the source code by clicking edit on any page with the side far you should find something in triple brackets {{{}}} which will be the name of a template being applied to the page. Make sure you are looking at the correct & relevant Template using the name! For instance Template:War is in triple brackets in the John Boyd source code. If you were to click through to the Template:War page, or put into your url bar www.ooda.wiki/index.php?title=Template:War and then hit edit/view source code, you will see how the sidebar is actually written out as a template. If you want to create a new template sidebar, you would do the exact same thing, find a page to be created & then create it if you have the permissions.

The picture for this section shows the section of relevant code.

In order to add a collapsible section in the main list of a sidebar, create something like below. New sections should have list15name..etc, list20name...etc.

| list10name = John Boyd

| list10title = John Boyd

| list10 =

Then the next portion will be the list inside that list, for instance below. On this how to page the * which are used in the actual code portion are rendered as bullets, and the ** is rendered as part of an indented list so be careful of that, as the actual source code will need them to be *. Also note that to make a link you will need to use double brackets [[]]. If you have uncompleted brackets, this will break the template.

Permissions and Group Management

Adding a User to a specific Page Permission

As a logged in Contubernium Admin, Go to the relevant page, and in the options menu for the page, the three dots in the top right, select from the drop down menu "Permissions" which is below the Watch option. In the Editor section of the page, add Regular Contubernium members for the Contubernium assigned to the page. Add Admin Contubernium Members to the Manager Role.

Extensions Used:

Skin:Citizen

Cite

To Do This guides explains how to create map definitions for the {{Location map}} family of templates.

Map definition data

The templates utilize any one of a set of map definitions. These are not forks but rather auxiliary pages and must have names following the pattern "Module:Location map/data/location" or "Template:Location map location", where location is the name of the area covered by the map. The template space is supported only for backward compatibility; all new map definitions should be created as modules. Important: If a new map has the same projection and boundaries as the old map (such as File:Iraq location map.svg and File:Iraq location map2.svg), a new definition should not be created; instead, the old definition should be used with the AlternativeMap parameter. To create a simple map definition module using an image of a map with an equirectangular projection having the equator as its standard parallel (aka plate carrée, “unprojected”, lat/lon projection):

  1. Create a new map image and upload it to Wikimedia commons or find an existing map on the same site.
  2. Create a module named Module:Location map/data/location, copy the content below into it and substitute the appropriate values.
  3. Create a page named Module:Location map/data/location/doc and follow the instructions under #Documentation.

As an example of a map that uses an equirectangular projection, we use Module:Location map/data/Belgium. Please do not experiment using active templates.

return {
	name = 'Belgium',
	top = 51.8,
	bottom = 49.2,
	left = 2.2,
	right = 6.9,
	image = 'Belgium location map.svg',
	image1 = 'Belgium relief location map.jpg'
}
Parameter Description
name The name of the area covered
top The latitude of the top edge of the image using decimal degrees
bottom The latitude of the bottom edge of the image
left longitude of the left edges of the image
right longitude of the right edges of the image
image The name of the image file on Commons
image1 The name of an alternate image, usually a relief map, which can be accessed using the relief parameter.

Maps of this type will work for small to mid sized areas. Module:Location map/data/USA Alabama is another example of a map description that uses an equirectangular projection. Notice that the image of the country is not what most would expect.

Advanced projections

Maps that use other projections, such as Module:Location map/data/USA, which uses an equidistant conic projection. require formulas which are used to calculate the x and y coordinates for the location mark. Understanding these formulas requires a familiarity with the subject, so you are more than welcome to skip this section.

The input $1 is the latitude and $2 is the longitude, both in decimal form. The expression follows the syntax of ParserFunction "#expr". The two output coordinates are defined such that the formula for x evaluates to 0 for the left edge of the image and 100 for the right edge; the formula for y evaluates to 0 for the top edge and 100 for the bottom edge.

Documentation

It is easiest to use the de facto template at Module:Location map/data/doc to generate the documentation page. Here is another example of what the documentation might look like:

<!-- Categories and interwikis go at the bottom of this page. -->
{{Module:Location map/data/doc|image=[[File:Belgium-CIA WFB Map.png|thumb|250px|Map of Belgium]]
|examples=
=== Location map, using default map (image) ===
{{Location map | Belgium
| width   = 200
| lat_deg = 50.85
| lon_deg = 4.35
| label   = Brussels
}}
<pre style="width:30em">
{{Location map | Belgium
| width   = 200
| lat_deg = 50.85
| lon_deg = 4.35
| label   = Brussels
}}
</pre>
{{clear}}

=== Location map many, using relief map (image1) ===
{{Location map many | Belgium
| relief   = yes
| width    = 200
| caption  = Two locations in Belgium
| lat1_deg = 50.85
| lon1_deg = 4.35
| label1   = Brussels
| lat2_deg = 51.22
| lon2_deg = 4.40
| label2   = Antwerp
}}
<pre style="width:30em">
{{Location map many | Belgium
| relief   = yes
| width    = 200
| caption  = Two locations in Belgium
| lat1_deg = 50.85
| lon1_deg = 4.35
| label1   = Brussels
| lat2_deg = 51.22
| lon2_deg = 4.40
| label2   = Antwerp
}}
</pre>
{{clear}}

=== Location map+, using AlternativeMap ===
{{Location map+ | Belgium
| AlternativeMap = Belgium relief location map.jpg
| width   = 200
| caption = Two locations in Belgium
| places  =
  {{Location map~ | Belgium
  | lat_deg = 50.85
  | lon_deg = 4.35
  | label   = Brussels
  }}
  {{Location map~ | Belgium
  | lat_deg = 51.22
  | lon_deg = 4.40
  | label   = Antwerp
  }}
}}
<pre style="width:35em">
{{Location map+ | Belgium
| AlternativeMap = Belgium relief location map.jpg
| width   = 200
| caption = Two locations in Belgium
| places  =
  {{Location map~ | Belgium
  | lat_deg = 50.85
  | lon_deg = 4.35
  | label   = Brussels
  }}
  {{Location map~ | Belgium
  | lat_deg = 51.22
  | lon_deg = 4.40
  | label   = Antwerp
  }}
}}
</pre>
}}
<includeonly>
<!-- Categories go here, and interwikis go on Wikidata: -->

[[Category:Belgium location map templates|Belgium location map templates]]

</includeonly>

The following parameters are taken by Module:Location map/data/doc:

Parameter Description
image An additional image to display (other than the one the location map uses) on the right side of the documentation page. If not specified, no additional image is displayed.
projection The type of projection the location map uses. If not specified, "an [[equirectangular projection]]" is used.
name The name to display in the map's documentation. If not specified, the actual name of the location map is used.
examples A section containing examples of the location map's usage. A {{clear}} template is automatically placed at the end of the examples. If not specified, no examples are output.
see also Additional links to place in the "See also" section.

All information about the map will be automatically taken from the map's definition itself.