routes/README.md

30 lines
903 B
Markdown

# Routes
A small static webpage for saving and sharing Google Maps route links.
## Features
- Add routes with name and Google Maps link (mandatory)
- Optional date, description, and uploaded picture
- Click route names to open saved Google Maps links
- Edit, remove, share, or copy route links
- Routes are stored on the webserver in `data/routes.json`
- Simple secret gate before the app opens
Deploy the files to a PHP-enabled webserver and open `index.html` in a browser.
## Secret
Create `config.js` from the example and set your secret there:
```sh
cp config.example.js config.js
```
```js
window.ROUTES_SECRET = "your-secret";
```
`config.js` is gitignored. `api.php` reads the same secret and stores shared routes in `data/routes.json`, which is also gitignored.
Make sure the webserver user can write to the `data/` directory. This is a simple shared-secret gate, not strong security.