X-Git-Url: https://git.openstreetmap.org./nominatim.git/blobdiff_plain/ec4cf9efd0b6e0d60cbe9674016a0519918324e2..f0f6fcf256c83176dbcda0d0fd4fec977ea8a0ad:/lib/template/details-error-html.php?ds=sidebyside diff --git a/lib/template/details-error-html.php b/lib/template/details-error-html.php index 5f075b93..1c6d2a0a 100644 --- a/lib/template/details-error-html.php +++ b/lib/template/details-error-html.php @@ -1,182 +1,133 @@ - - - OpenStreetMap Nominatim: <?php echo $aPointDetails['localname'];?> - - - - - - -
-

-
-
Type:
- OSM: '.$sOSMType.' '. $aPointDetails['osm_id'].'
'; -?> -

This object has an invalid geometry.

-

Details: ".($sVal?$sVal:' ').""; -} -else -{ - echo ($sVal?$sVal:' '); -} + function osm_link($aFeature) + { + $sOSMType = ($aFeature['osm_type'] == 'N'?'node':($aFeature['osm_type'] == 'W'?'way':($aFeature['osm_type'] == 'R'?'relation':''))); + if ($sOSMType) { + return ''.$sOSMType.' '.$aFeature['osm_id'].''; + } + return ''; + } + + function osm_map_url($aFeature) + { + $sLon = $aFeature['error_x']; + $sLat = $aFeature['error_y']; + + if (isset($sLat)) + { + $sOSMType = ($aFeature['osm_type'] == 'N'?'node':($aFeature['osm_type'] == 'W'?'way':($aFeature['osm_type'] == 'R'?'relation':''))); + if ($sOSMType) + { + return "http://www.openstreetmap.org/?lat=".$sLat."&lon=".$sLon."&zoom=18&layers=M&".$sOSMType."=".$aFeature['osm_id']; + } + } + return ''; + } + + function josm_edit_url($aFeature) + { + $fWidth = 0.0002; + $sLon = $aFeature['error_x']; + $sLat = $aFeature['error_y']; + + if (isset($sLat)) + { + return "http://localhost:8111/load_and_zoom?left=".($sLon-$fWidth)."&right=".($sLon+$fWidth)."&top=".($sLat+$fWidth)."&bottom=".($sLat-$fWidth); + } + + $sOSMType = ($aFeature['osm_type'] == 'N'?'node':($aFeature['osm_type'] == 'W'?'way':($aFeature['osm_type'] == 'R'?'relation':''))); + if ($sOSMType) + { + return 'http://localhost:8111/import?url=http://www.openstreetmap.org/api/0.6/'.$sOSMType.'/'.$aFeature['osm_id'].'/full'; + // Should be better to load by object id - but this doesn't seem to zoom correctly + // return " Remote Control (JOSM / Merkaartor)"; + } + return ''; + } + + function potlach_edit_url($aFeature) + { + $fWidth = 0.0002; + $sLat = $aFeature['error_y']; + $sLon = $aFeature['error_x']; + + if (isset($sLat)) + { + return "http://www.openstreetmap.org/edit?editor=potlatch2&bbox=".($sLon-$fWidth).",".($sLat-$fWidth).",".($sLon+$fWidth).",".($sLat+$fWidth); + } + return ''; + } + + + ?> -

Edit: in Remote Controll (JOSM / Merkaartor)"; - echo " | Potlatch 2"; -} -else -{ - echo " Remote Controll (JOSM / Merkaartor)"; - // Should be better to load by object id - but this doesn't seem to zoom correctly - //echo " Remote Controll (JOSM / Merkaartor)"; -} - -?>

- - - + +
+
+
+ + +

+
+

This object has an invalid geometry.

+ +
+ Type: +
+ +
+ OSM: +
+ + +

Error

+

+ +

+ + view on osm.org + + +

Edit

+ +
+
+
+
+
+ +
+ + + + + + + + \ No newline at end of file