Google Street View

From MediaWiki Widgets

Jump to: navigation, search

This widget allows you to add Google Street View widget to your wiki page.

Created by Sergey Chernyshev

To insert this widget, use the following code:

{{#widget:Google Street View
|key=ABQIAAAAq_i4aTseMGLic8bgu1NQHRRuMGSDM4hOrlKevQrS9qsdJ_NOCxRsXLLNmhAg5xMn9btyuqHxCavIxw
|lat=40.758153
|lng=-73.985355
|yaw=370.64659986187695
|pitch=-20
|zoom=0
}}

[edit] Parameters

  • key - Google developer key for your site (you must get your own or it will not work).
  • lat - lattitude of street view location
  • lng - longitude of street view location
  • height and width define view dimensions, 420x350 is default
  • yaw - defines the rotation angle around the camera locus in degrees relative from true north. Yaw angles are measured clockwise (90 degrees is true east)
  • pitch - defines the angle variance "up" or "down" from the camera's initial default pitch, which is often (but not always) flat horizontal. (For example, an image taken on a hill will likely exhibit a default pitch that is not horizontal.) Pitch angles are measured with negative values looking up (to -90 degrees straight up and orthogonal to the default pitch) and positive values looking down (to +90 degrees straight down and orthogonal to the default pitch)
  • zoom - defines the zoom level of this view (effectively proscribing the "field of view") with 0 being fully zoomed-out. Different Street View locations may provide higher or lower zoom levels.

[edit] Bookmarklet

Sometimes it's hard to get all the parameters you need for a Street View to display - coming up with longitude and latitude, direction (yaw), pitch, correct zoom levels and so on might take too much time.

To help with this problem, we created a bookmarklet that you can use on Google Maps site to grab Street View widget code for current location with just one click.

Drag this bookmarklet Maps Widget Code to your links toolbar and just click it when you want to post a location on the map to your wiki.

You can insert this bookmarklet (with your Google Maps developer key preset) into your wiki using Google Maps bookmarklet widget.

[edit] Related widgets

[edit] Sample result


Google Street View widget
Author:Sergey Chernyshev
Widget Provider:Google Street View
Widget Code:Widget:Google Street View

To copy this widget to your wiki, cut and paste the entire source of Google Street View widget code page into a page called Widget:Google Street View on your wiki.

If you don't have Widget extension set up on your wiki, go to extension page on MediaWiki.org and follow installation instructions.