
- Javascript Basics Tutorial
- Javascript - Home
- Javascript - Overview
- Javascript - Syntax
- Javascript - Enabling
- Javascript - Placement
- Javascript - Variables
- Javascript - Operators
- Javascript - If...Else
- Javascript - Switch Case
- Javascript - While Loop
- Javascript - For Loop
- Javascript - For...in
- Javascript - Loop Control
- Javascript - Functions
- Javascript - Events
- Javascript - Cookies
- Javascript - Page Redirect
- Javascript - Dialog Boxes
- Javascript - Void Keyword
- Javascript - Page Printing
- JavaScript Objects
- Javascript - Objects
- Javascript - Number
- Javascript - Boolean
- Javascript - Strings
- Javascript - Arrays
- Javascript - Date
- Javascript - Math
- Javascript - RegExp
- Javascript - HTML DOM
- JavaScript Advanced
- Javascript - Error Handling
- Javascript - Validations
- Javascript - Animation
- Javascript - Multimedia
- Javascript - Debugging
- Javascript - Image Map
- Javascript - Browsers
- JavaScript Useful Resources
- Javascript - Questions And Answers
- Javascript - Quick Guide
- Javascript - Functions
- Javascript - Resources
Error codes returned in the PositionError object HTML5 Geolocation
The following table describes the possible error codes returned in the PositionError object:
Code | Constant | Description |
---|---|---|
0 | UNKNOWN_ERROR | The method failed to retrieve the location of the device due to an unknown error. |
1 | PERMISSION_DENIED | The method failed to retrieve the location of the device because the application does not have permission to use the Location Service. |
2 | POSITION_UNAVAILABLE | The location of the device could not be determined. |
3 | TIMEOUT | The method was unable to retrieve the location information within the specified maximum timeout interval. |
Following is a sample code, which makes use of the PositionError object. Here errorHandler method is a callback method:
function errorHandler( err ) { if (err.code == 1) { // access is denied } ... }
- Related Articles
- Error Codes returned in the PositionError object in HTML5 Geolocation
- HTML5 geolocation 'permission denied' error in Mobile Safari
- Error Correcting Codes - Hamming codes
- HTML5 Geolocation in Safari 5
- Error Correcting Codes - Reed-Solomon codes
- HTML5 Geolocation without SSL connection
- Explain the Hamming Codes in Error Correction
- Error-Detecting Codes - Parity
- Error-Detecting Codes - Checksums
- Error Correcting Codes - Low-Density Parity Check Codes
- How to handle Geolocation errors in HTML5?
- How to use geolocation coordinates in HTML5?
- Error correcting codes in Computer Networks
- Chrome and HTML5 GeoLocation denial callback
- What are Error-Detecting Codes?

Advertisements