(Created page with "==== '''Bookmarklets''' ==== '''Open in TIMS''' <nowiki>javascript:(function(){var projI=new OpenLayers.Projection("EPSG:900913");var projE=new OpenLayers.Projection("EPSG:4...") |
|||
Line 2: | Line 2: | ||
'''Open in TIMS''' | '''Open in TIMS''' | ||
{{pre2|<nowiki>javascript:(function(){var projI=new OpenLayers.Projection("EPSG:900913");var projE=new OpenLayers.Projection("EPSG:4326");var center_lonlat=(new OpenLayers.LonLat(wazeMap.center.lon,wazeMap.center.lat)).transform(projI,projE);var topleft=(new OpenLayers.LonLat(wazeMap.getExtent().left,wazeMap.getExtent().top)).transform(projI,projE);var bottomright=(new OpenLayers.LonLat(wazeMap.getExtent().right,wazeMap.getExtent().bottom)).transform(projI,projE);var lat=Math.round(center_lonlat.lat*1000000)/1000000;var lon=Math.round(center_lonlat.lon*1000000)/1000000;var spn=Math.abs(topleft.lat-bottomright.lat)+','+Math.abs(topleft.lon-bottomright.lon);var newZoom= (wazeMap.zoom + 12);window.open('https://gis.dot.state.oh.us/tims/map?center='+lon+','+lat+'&level='+newZoom+'&visiblelayers=Assets:-1%7CEnvironmental:-1%7CProjects:-1%7CRoadway Information:-1%7CStrategic Transportation System:-1','ODOT TIMS');})();</nowiki>}} |
Revision as of 20:20, 2 February 2016
Bookmarklets
Open in TIMS
javascript:(function(){var projI=new OpenLayers.Projection("EPSG:900913");var projE=new OpenLayers.Projection("EPSG:4326");var center_lonlat=(new OpenLayers.LonLat(wazeMap.center.lon,wazeMap.center.lat)).transform(projI,projE);var topleft=(new OpenLayers.LonLat(wazeMap.getExtent().left,wazeMap.getExtent().top)).transform(projI,projE);var bottomright=(new OpenLayers.LonLat(wazeMap.getExtent().right,wazeMap.getExtent().bottom)).transform(projI,projE);var lat=Math.round(center_lonlat.lat*1000000)/1000000;var lon=Math.round(center_lonlat.lon*1000000)/1000000;var spn=Math.abs(topleft.lat-bottomright.lat)+','+Math.abs(topleft.lon-bottomright.lon);var newZoom= (wazeMap.zoom + 12);window.open('https://gis.dot.state.oh.us/tims/map?center='+lon+','+lat+'&level='+newZoom+'&visiblelayers=Assets:-1%7CEnvironmental:-1%7CProjects:-1%7CRoadway Information:-1%7CStrategic Transportation System:-1','ODOT TIMS');})();