A responsive and mobile-friendly web application that tracks a user's real-time GPS location and provides the ability to download the collected data as a JSON file.
- Track your location in real-time with updates every 5 seconds
- Visualize your location and movement path on an interactive map
- Download your location history as a JSON file
- Simple, intuitive interface that works on both desktop and mobile devices
- Open the
index.htmlfile in a modern web browser - Allow location permissions when prompted
- Click the "Start" button to begin tracking your location
- Your current position will be displayed on the map with a marker
- Your movement path will be visualized as a blue line
- Click "Stop" to pause tracking
- Click "Download JSON" to save your location data
This application is built using:
- HTML5, CSS3, and JavaScript (ES6+)
- Leaflet.js for the interactive map
- HTML5 Geolocation API for accessing location data
The downloaded JSON file follows this format:
[
{
"latitude": 17.385044,
"longitude": 78.486671,
"timestamp": "2024-07-20T10:00:00Z"
},
{
"latitude": 17.385045,
"longitude": 78.486672,
"timestamp": "2024-07-20T10:00:05Z"
}
]