Demo VisualData 1.0 / Geolocation

Geolocation: Difference between revisions

From Wikisphere
Jump to navigation Jump to search
(VisualData update)
No edit summary
Tag: 2017 source edit
(27 intermediate revisions by 2 users not shown)
Line 1: Line 1:
This page demonstrates the use of [https://www.mediawiki.org/wiki/Extension:VisualData/Geolocation VisualData/Geolocation] in conjunction with the [https://www.mediawiki.org/wiki/Extension:Maps Extension:Maps].  
This page demonstrates the use of   [https://www.mediawiki.org/wiki/Extension:VisualData/Geolocation VisualData/Geolocation] in conjunction with the [https://www.mediawiki.org/wiki/Extension:Maps Extension:Maps]. (click the tab "Edit data" above to edit the related form) 
 
{{#visualdataprint:{{FULLPAGENAME}}
{{#visualdataprint:{{FULLPAGENAME}}
|schema=Geolocation  
|schema=Geolocation
|format=template
|template=Geolocation map
|template?geolocation=Geolocation map
|format=template
}}
}}
 


It is composed by the following elements:
It is composed by the following elements:
Line 18: Line 18:
<pre>
<pre>
{{#visualdataprint:{{FULLPAGENAME}}
{{#visualdataprint:{{FULLPAGENAME}}
|schema=Geolocation  
|schema=Geolocation
|format=template
|template=Geolocation map
|template?geolocation=Geolocation map
|format=template
}}
}}
</pre>
</pre>
Line 28: Line 28:


<pre>
<pre>
{{#display_map: {{{latitude}}},{{{longitude}}}  
{{#display_map: {{{geolocation/latitude}}},{{{geolocation/longitude}}}  
|zoom= {{#expr: {{{zoom}}} round 0 }}
|zoom= {{#expr: {{{geolocation/zoom}}} round 0 }}
|width=400
|width=400
}}
}}
</pre>
</pre>


<!--
Note that the printouts <code>geolocation/latitude</code>, <code>geolocation/longitude</code> and <code>geolocation/zoom</code> (visible [https://wikisphere.org/wiki/Demo_VisualData/Geolocation?slot=jsondata here]) are accessible through the only property name since the template is applied within the subitem <code>geolocation</code> through the following parameter:
Note that the printouts <code>geolocation/latitude</code>, <code>geolocation/longitude</code> and <code>geolocation/zoom</code> (visible [https://wikisphere.org/wiki/Demo_VisualData/Geolocation?slot=jsondata here]) are accessible through the only property name since the template is applied within the subitem <code>geolocation</code> through the following parameter:


Line 39: Line 40:
|template?geolocation=Geolocation map
|template?geolocation=Geolocation map
</pre>
</pre>
 
-->




jsondata
Line 3: Line 3:
         "Geolocation": {
         "Geolocation": {
             "geolocation": {
             "geolocation": {
                 "latitude": 40.394960365202394,
                 "latitude": 38.731867402360336,
                 "longitude": 74.13338216157695,
                 "longitude": -27.207651547736617,
                 "zoom": 4.260342783895178
                 "zoom": 9.724027220263949
             }
             }
         }
         }
     }
     }
}
}

Revision as of 10:14, 8 April 2024

This page demonstrates the use of VisualData/Geolocation in conjunction with the Extension:Maps. (click the tab "Edit data" above to edit the related form)

Loading map...


It is composed by the following elements:

1) the schema Geolocation, which is of course createable/editable from here or here.

2) The data entered in the same action tab Edit data

3) The following parser function

{{#visualdataprint:{{FULLPAGENAME}}
|schema=Geolocation
|template=Geolocation map
|format=template
}}


The template Template:Geolocation map containing the call to the display_map parser function in the following form:

{{#display_map: {{{geolocation/latitude}}},{{{geolocation/longitude}}} 
|zoom= {{#expr: {{{geolocation/zoom}}} round 0 }}
|width=400
}}


4) That's it, enjoy the power of Maptiler combined with VisualData and the Maps extension.


See also