• Share
  • Email
  • Embed
  • Like
  • Save
  • Private Content
Geoloaction
 

Geoloaction

on

  • 246 views

 

Statistics

Views

Total Views
246
Views on SlideShare
246
Embed Views
0

Actions

Likes
0
Downloads
4
Comments
0

0 Embeds 0

No embeds

Accessibility

Categories

Upload Details

Uploaded via as Microsoft PowerPoint

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

    Geoloaction Geoloaction Presentation Transcript

    • Jason
    • Support
    • Geolocation API The Geolocation API exposes the latitude andlongitude to JavaScript in a webpage by usingthe geolocation object, which is a child objectof the window.navigator.
    • Geolocation API - Method getCurrentPosition(successCallback,[errorCallback],[options]) The function specified bythesuccessCallback parameter takesone position parameter. The function specified bytheerrorCallback parameter takesone positionError parameter
    • Geolocation API - GeopositionPositionPropertiesCoordsPropertiesExplaincoordslatitude The latitude of the location specified inthe coordinates objectlongitude The longitude of the location specified inthe coordinates objectaltitude Specifies the altitude, in meters, ofthe coordinates object.accuracy Gets the accuracy of the latitudeand longitude properties , in meters.altitudeAccuracy Accuracy of the altitude property, in meters.heading Specifies a direction of travelspeed Current ground speed of the device runningInternet Explorer, specified in meters per second.timestamp Gets the time associated with the geographic information
    • Geolocation API - PositionErrorProperties Explaincode Error CodeUNKNOWN_ERROR Uncertainty ErrorPERMISSION_DENIED The user has denied permission for the website to accessgeographic information.POSITION_UNAVAILABLE The geographic location could not be determined.TIMEOUT The request did not complete within the time allowed.message Gets an error message for debugging purposes.
    • Geolocation API - OptionProperties ExplainenableHighAccuracy bool (false) Obtain the most accurate position possible, orfalse to optimize in favor of performance andpower consumption.timeout Integer (none) An Integer value that indicates the time, inmilliseconds, allowed for obtaining the position.maximumAge Integer (0) An Integer value indicating the maximum age,in milliseconds, of cached position information.
    • Geolocation API - Method watchPosition(successCallback,[errorCallback],[options]) Returns :WatchID [Integer] Begins listening for updates to the currentgeographical location of the device runningthe client.
    • Geolocation API - Method clearWatch ( WatchID ) Stops listening for updates to the currentgeographical location.
    • Reference http://msdn.microsoft.com/en-us/library/ie/hh772290(v=vs.85).aspx http://kuro.tw/blog/2011/12/07/html5-geolocation-api