Difference between revisions of "Widget:OSM-Sudoroom-dev"

From Sudo Room
Jump to navigation Jump to search
(gratuitous space)
(dimensions need units)
Line 2: Line 2:
 
This is a homebrew attempt at making an OSM widget in mediawiki, fancier than the official extension will allow.
 
This is a homebrew attempt at making an OSM widget in mediawiki, fancier than the official extension will allow.
 
</noinclude><includeonly>
 
</noinclude><includeonly>
   <div style="width:<!--{$w|escape:'html'|default:425}-->;height:<!--{$h|escape:'html'|default:350}-->;border:1px solid black;margin:0px;" id="mapdiv"></div>
+
   <div style="width:<!--{$w|escape:'html'|default:425}-->px;height:<!--{$h|escape:'html'|default:350}-->px;border:1px solid black;margin:0px;" id="mapdiv"></div>
 
   <script src="https://sudoroom.org/openlayers/OpenLayers.js"></script>
 
   <script src="https://sudoroom.org/openlayers/OpenLayers.js"></script>
 
   <script>
 
   <script>
Line 8: Line 8:
 
     map.addLayer(new OpenLayers.Layer.OSM());
 
     map.addLayer(new OpenLayers.Layer.OSM());
  
 
 
     var lonLat = new OpenLayers.LonLat( <!--{$mklon|escape:'html'|default:-122.267652}--> ,<!--{$mklat|escape:'html'|default:37.810963}--> )
 
     var lonLat = new OpenLayers.LonLat( <!--{$mklon|escape:'html'|default:-122.267652}--> ,<!--{$mklat|escape:'html'|default:37.810963}--> )
 
           .transform(
 
           .transform(

Revision as of 20:04, 3 March 2014

This is a homebrew attempt at making an OSM widget in mediawiki, fancier than the official extension will allow.