π§ͺ GPS Tracking System - Test Dashboard
π€ Current User: test_user
1οΈβ£ Database Connection Test
β
Database connection successful!
β
Table s_autolocations exists
Table Structure:
| Field | Type | Null | Key | Default |
|---|
| id | int(11) | NO | PRI | |
| user_name | varchar(50) | YES | MUL | |
| latitude | decimal(10,8) | YES | | |
| longitude | decimal(11,8) | YES | | |
| sdate | timestamp | YES | MUL | CURRENT_TIMESTAMP |
| sal_ex | varchar(10) | YES | | |
π Total GPS records in database: 24282
2οΈβ£ Browser Geolocation API Test
β³ Checking GPS support...
3οΈβ£ Test Logs
4οΈβ£ Recent GPS Records (Last 10)
| ID | User | Date/Time | Latitude | Longitude | Map |
|---|
| 25048 | Malinda | 2026-11-17 13:56:55 | 6.93383170 | 79.86459830 | πΊοΈ View |
| 25047 | Malinda | 2026-11-17 13:55:57 | 6.93383030 | 79.86460260 | πΊοΈ View |
| 25046 | Malinda | 2026-11-17 13:55:29 | 6.93382590 | 79.86460100 | πΊοΈ View |
| 25045 | Chanka | 2026-11-17 13:54:26 | 6.93383070 | 79.86459790 | πΊοΈ View |
| 25044 | Chanka | 2026-11-17 13:50:17 | 6.93383070 | 79.86459790 | πΊοΈ View |
| 25043 | Chanka | 2026-11-17 13:48:53 | 6.93382600 | 79.86459900 | πΊοΈ View |
| 25042 | Chanka | 2026-11-17 13:48:05 | 6.93382900 | 79.86459710 | πΊοΈ View |
| 25041 | Chanka | 2026-11-17 13:47:12 | 6.93382400 | 79.86459710 | πΊοΈ View |
| 25040 | Chanka | 2026-11-17 13:46:13 | 6.93372640 | 79.86482270 | πΊοΈ View |
| 25039 | Chanka | 2026-11-17 12:31:25 | 6.93383120 | 79.86459760 | πΊοΈ View |
5οΈβ£ How to Use
Automatic Tracking:
- GPS tracking starts automatically when this page loads
- First location is captured immediately
- Subsequent captures occur every 10 minutes
- Check browser console (F12) for detailed logs
Manual Testing:
- Click "Test GPS Capture Now" to capture location immediately
- Check the "Recent GPS Records" section for saved data
- View locations on Google Maps using the map links
Troubleshooting:
- Allow location permissions when browser asks
- Check browser console (F12 β Console) for errors
- Verify database table exists using test above
- Try refreshing the page if GPS doesn't work
6οΈβ£ Useful SQL Queries
-- View all GPS records for current user
SELECT * FROM s_autolocations WHERE user_name = 'test_user' ORDER BY sdate DESC;
-- View GPS records from today
SELECT * FROM s_autolocations WHERE DATE(sdate) = CURDATE() ORDER BY sdate DESC;
-- Count records per user
SELECT user_name, COUNT(*) as total FROM s_autolocations GROUP BY user_name;
-- Delete all test records
DELETE FROM s_autolocations WHERE user_name = 'test_user';