url-processor/public/test.html
Alexander Borsuk 36f8d2dc88 Removed local gpx/kml/kmz files as they're not properly responded by CF, changed their location to the planet cdn
This reverts commit c0b6eb3102.

Signed-off-by: Alexander Borsuk <me@alex.bio>
2024-08-27 13:20:16 +02:00

209 lines
11 KiB
HTML
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!-- Template which is processed and returned by worker. -->
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no, viewport-fit=cover" />
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>Organic Maps API and Deep Links Test Page</title>
<style>
html {
width: 100%;
height: 100%;
margin: 0;
padding: 0;
}
body {
margin: 1rem;
padding: 0;
background-color: #FFF;
font-family: sans-serif;
font-weight: lighter;
}
li {
line-height: 1.5rem;
}
a:hover {
cursor: pointer;
}
</style>
</head>
<body>
<h1><a href="https://organicmaps.app">Organic Maps</a> API and Deep Links Test Page</h1>
<p>
Here you can test some supported API/deep links scenarios.
Please also check Organic Maps <a href="https://github.com/organicmaps/api-android/">Android API</a>
and <a href="https://github.com/organicmaps/api-ios/">iOS API</a> code and examples.
And <a href="mailto:bugs@organicmaps.app?subject=Organic Maps API Bugs">let us know</a> if something doesn't work.
</p>
<h3>Organic Maps links:</h3>
<h4>Show a point with an optional title on the map (used in sharing)</h4>
<ol>
<li><a href="om://o4B4pYZsRs">om://o4B4pYZsRs</a></li>
<li><a href="om://o4B4pYZsRs/">om://o4B4pYZsRs/</a></li>
<li><a href="om://o4B4pYZsRs/Zoo_Zürich">om://o4B4pYZsRs/Zoo_Zürich</a></li>
<li><a href="http://omaps.app/o4B4pYZsRs">http://omaps.app/o4B4pYZsRs</a></li>
<li><a href="http://omaps.app/o4B4pYZsRs/">http://omaps.app/o4B4pYZsRs/</a></li>
<li><a href="http://omaps.app/o4B4pYZsRs/Zoo_Zürich">http://omaps.app/o4B4pYZsRs/Zoo_Zürich</a></li>
<li><a href="https://omaps.app/o4B4pYZsRs">https://omaps.app/o4B4pYZsRs</a></li>
<li><a href="https://omaps.app/o4B4pYZsRs/">https://omaps.app/o4B4pYZsRs/</a></li>
<li><a href="https://omaps.app/o4B4pYZsRs/Zoo_Zürich">https://omaps.app/o4B4pYZsRs/Zoo_Zürich</a></li>
</ol>
<h4>Show one or more points with titles on the map</h4>
<ol>
<li><a href="om://map?v=1&ll=22.17319,-159.65687&n=Kalalau%20Camping&ll=22.17168,-159.66096&n=Dream%20Beach&ll=22.17182,-159.65776">
om://map?v=1&ll=22.17319,-159.65687&n=Kalalau%20Camping&ll=22.17168,-159.66096&n=Dream%20Beach&ll=22.17182,-159.65776
</a></li>
<li><a href="https://omaps.app/map?v=1&ll=22.17319,-159.65687&n=Kalalau%20Camping&ll=22.17168,-159.66096&n=Dream%20Beach&ll=22.17182,-159.65776">
https://omaps.app/map?v=1&ll=22.17319,-159.65687&n=Kalalau%20Camping&ll=22.17168,-159.66096&n=Dream%20Beach&ll=22.17182,-159.65776
</a></li>
</ol>
<h4>Build a route (car, foot, subway, bicycle)</h4>
<ol>
<li><a href="om://route?v=1&sll=50.183933,8.942871&saddr=Start%20Point&dll=49.998912,8.278198&daddr=EndPoint&type=vehicle">
om://route?sll=50.183933,8.942871&saddr=Start%20Point&dll=49.998912,8.278198&daddr=EndPoint&type=vehicle
</a></li>
<li><a href="https://omaps.app/route?v=1&sll=50.183933,8.942871&saddr=Start%20Point&dll=49.998912,8.278198&daddr=EndPoint&type=vehicle">
https://omaps.app/route?sll=50.183933,8.942871&saddr=Start%20Point&dll=49.998912,8.278198&daddr=EndPoint&type=vehicle
</a></li>
<li><a href="om://route?v=1&sll=47.395084,8.552692&saddr=Start%20Point&dll=47.38568,8.566878&daddr=EndPoint&type=pedestrian">
om://route?sll=47.395084,8.552692&saddr=Start%20Point&dll=47.38568,8.566878&daddr=EndPoint&type=pedestrian
</a></li>
<li><a href="https://omaps.app/route?v=1&sll=47.395084,8.552692&saddr=Start%20Point&dll=47.38568,8.566878&daddr=EndPoint&type=pedestrian">
https://omaps.app/route?sll=47.395084,8.552692&saddr=Start%20Point&dll=47.38568,8.566878&daddr=EndPoint&type=pedestrian
</a></li>
<li><a href="om://route?v=1&sll=47.325975,8.699972&saddr=Start%20Point&dll=47.374074,8.649849&daddr=EndPoint&type=bicycle">
om://route?sll=47.325975,8.699972&saddr=Start%20Point&dll=47.374074,8.649849&daddr=EndPoint&type=bicycle
</a></li>
<li><a href="https://omaps.app/route?v=1&sll=47.325975,8.699972&saddr=Start%20Point&dll=47.374074,8.649849&daddr=EndPoint&type=bicycle">
https://omaps.app/route?sll=47.325975,8.699972&saddr=Start%20Point&dll=47.374074,8.649849&daddr=EndPoint&type=bicycle
</a></li>
<li><a href="om://route?v=1&sll=1.337412,103.696997&saddr=Start%20Point&dll=1.343107,103.732609&daddr=EndPoint&type=transit">
om://route?sll=1.337412,103.696997&saddr=Start%20Point&dll=1.343107,103.732609&daddr=EndPoint&type=transit
</a></li>
<li><a href="https://omaps.app/route?v=1&sll=1.337412,103.696997&saddr=Start%20Point&dll=1.343107,103.732609&daddr=EndPoint&type=transit">
https://omaps.app/route?sll=1.337412,103.696997&saddr=Start%20Point&dll=1.343107,103.732609&daddr=EndPoint&type=transit
</a></li>
</ol>
<h4>Search for something</h4>
<ol>
<li><a href="om://search?cll=47.3813,8.5889&locale=de&query=Mame">
om://search?cll=47.3813,8.5889&locale=de&query=Mame
</a></li>
<li><a href="https://omaps.app/search?cll=47.3813,8.5889&locale=de&query=Mame">
https://omaps.app/search?cll=47.3813,8.5889&locale=de&query=Mame
</a></li>
<li><a href="om://search?locale=ru&query=Цюрих">
om://search?locale=ru&query=Цюрих
</a></li>
<li><a href="https://omaps.app/search?locale=ru&query=Цюрих">
https://omaps.app/search?locale=ru&query=Цюрих
</a></li>
<li><a href="om://search?cll=47.3813,8.5889&query=restaurants">
om://search?cll=47.3813,8.5889&query=restaurants
</a></li>
<li><a href="https://omaps.app/search?cll=47.3813,8.5889&query=restaurants">
https://omaps.app/search?cll=47.3813,8.5889&query=restaurants
</a></li>
<li><a href="om://search?query=Minsk">
om://search?query=Minsk
</a></li>
<li><a href="https://omaps.app/search?query=Minsk">
https://omaps.app/search?query=Minsk
</a></li>
<li><a href="om://search?cll=47.3813,8.5889&query=restaurants&map=">
om://search?cll=47.3813,8.5889&query=restaurants&map=
</a></li>
<li><a href="https://omaps.app/search?cll=47.3813,8.5889&query=restaurants&map=">
https://omaps.app/search?cll=47.3813,8.5889&query=restaurants&map=
</a></li>
</ol>
<h3><a href="https://en.wikipedia.org/wiki/Geo_URI_scheme">Geo url scheme</a></h3>
<ol>
<li><a href="geo:37.786971,-122.399677">geo:37.786971,-122.399677</a> - show a point in San Francisco.</li>
<li><a href="geo:37.786971,-122.399677,1000">geo:37.786971,-122.399677,1000</a> - show a point in San Francisco; altitude=1000 is ignored</li>
<li><a href="geo:37.786971,-122.399677;u=35">geo:37.786971,-122.399677;u=35</a> - show a point in San Francisco; u=35 is ignored</li>
<li><a href="geo:37.786971,-122.399677?z=17">geo:37.786971,-122.399677?z=17</a> - show a point in San Francisco with zoom=17</li>
<li><a href="geo:0,0?q=37.78918,-122.40335">geo:0,0?q=37.78918,-122.40335</a> - show a point in San Francisco</li>
<li><a href="geo:0,0?q=37.78918,-122.40335&z=16">geo:0,0?q=37.78918,-122.40335&z=16</a> - show a point in San Francisco with zoom=16</li>
<li><a href="geo:35.341714,33.32231(Custom%20Title)">geo:35.341714,33.32231(Custom%20Title)</a> - show a point with 'Custom Title' in Kyrenia</li>
<li><a href="geo:35.3381607,33.3290564?q=Kyrenia%20Castle">geo:35.3381607,33.3290564?q=Kyrenia%20Castle</a> - search for 'Kyrenia Castle' in 35.3381607,33.3290564</li>
<li><a href="geo:0,0?q=Where%20to%20eat">geo:0,0?q=Where%20to%20eat</a> - search for 'Where to eat' in the current (last) location</li>
<li><a href="geo:0,0(Null%20Island)">geo:0,0(Null%20Island)</a> - show 0,0 point in Atlantic Ocean with 'Null Island' title</li>
<li><a href="geo:0,0?q=Restaurant">geo:0,0?q=Restaurant</a> - search for 'Restaurant' type around current position</li>
<li><a href="geo:0,0?q=87G7MXQ4%2BM5">geo:0,0?q=87G7MXQ4%2BM5</a> - search for Plus Code '87G7MXQ4+M5' from current position (strings in Geo URI must be encoded so '+' is '%2B')</li>
</ol>
<h3>MAPS.ME url scheme</h3>
<ol>
<li><a href="ge0://o4B4pYZsRs">ge0://o4B4pYZsRs</a></li>
<li><a href="ge0://o4B4pYZsRs/">ge0://o4B4pYZsRs/</a></li>
<li><a href="ge0://o4B4pYZsRs/Zoo_Zürich">ge0://o4B4pYZsRs/Zoo_Zürich</a></li>
</ol>
<h3>Android intent</h3>
<ol>
<li><a href="intent://#Intent;package=app.organicmaps;scheme=om;end;">intent://#Intent;package=app.organicmaps;scheme=om;end;</a></li>
<li><a href="intent://#Intent;package=app.organicmaps.beta;scheme=om;end;">intent://#Intent;package=app.organicmaps.beta;scheme=om;end;</a></li>
<li><a href="intent://#Intent;package=app.organicmaps.debug;scheme=om;end;">intent://#Intent;package=app.organicmaps.debug;scheme=om;end;</a></li>
</ol>
<h3>Google url scheme</h3>
<ol>
<li><a href="https://maps.google.com/maps?z=16&q=Mezza9%401.3067198,103.83282">https://maps.google.com/maps?z=16&q=Mezza9%401.3067198,103.83282</a></li>
<li><a href="https://maps.google.com/maps?z=16&q=House+of+Seafood+%40+180%401.356706,103.87591">https://maps.google.com/maps?z=16&q=House+of+Seafood+%40+180%401.356706,103.87591</a></li>
<li><a href="https://www.google.com/maps/place/Falafel+M.+Sahyoun/@33.8904447,35.5044618,16z">https://www.google.com/maps/place/Falafel+M.+Sahyoun/@33.8904447,35.5044618,16z</a></li>
<li><a href="https://www.google.com/maps?q=55.751809,37.6130029">https://www.google.com/maps?q=55.751809,37.6130029</a></li>
</ol>
<h3>OpenStreetMap url scheme</h3>
<ol>
<li><a href="https://www.openstreetmap.org/#map=16/33.89041/35.50664">https://www.openstreetmap.org/#map=16/33.89041/35.50664</a></li>
<li><a href="https://www.openstreetmap.org/search?query=Falafel%20Sahyoun#map=19/33.89041/35.50665">https://www.openstreetmap.org/search?query=Falafel%20Sahyoun#map=19/33.89041/35.50665</a></li>
</ol>
<h3>2GIS url scheme</h3>
<ol>
<li><a href="https://2gis.ru/moscow/firm/4504127908589159/center/37.6186,55.7601/zoom/15.9764">https://2gis.ru/moscow/firm/4504127908589159/center/37.6186,55.7601/zoom/15.9764</a></li>
<li><a href="https://2gis.ru/moscow/firm/4504127908589159?m=37.618632%2C55.760069%2F15.232">https://2gis.ru/moscow/firm/4504127908589159?m=37.618632%2C55.760069%2F15.232</a></li>
</ol>
<h3>KML, KMZ and GPX test files</h3>
<ol>
<li><a href="https://cdn.organicmaps.app/download/Kaipǎwa Trig.kml">Kaipǎwa Trig.kml</a></li>
<li><a href="https://cdn.organicmaps.app/download/Kaipǎwa Trig.kmz">Kaipǎwa Trig.kmz</a></li>
<li><a href="https://cdn.organicmaps.app/download/Wairǎkei Терраса.gpx">Wairǎkei Терраса.gpx</a></li>
</ol>
<div id="console">
</div>
<div id="map" class="map"></div>
<script type="text/javascript">
var LOG = (str) => document.getElementById('console').textContent += str + '\n';
var isiOS = navigator.platform.substring(0, 2) === 'iP' || // iPhone, iPad, iPod, including simulators.
(navigator.userAgent.indexOf('Mac') !== -1 && 'ontouchend' in document); // iPad on iOS 13.
var isAndroid = !isiOS && /(android)/i.test(navigator.userAgent);
var isDesktop = !isiOS && !isAndroid;
LOG(`iOS: ${isiOS}, Android: ${isAndroid}, Desktop: ${isDesktop}`);
</script>
</body>
</html>