NOTICE: help.openstreetmap.org is no longer in use from 1st March 2024. Please use the OpenStreetMap Community Forum

Hi,

In my application I am using OSM Map. I am displaying different trajectories/routes in different layer. Now my requirement is like,

If I click any of displayed trajectory, it should create a popup to display information regarding that trajectory/route.

Can you suggest different approach to go through with this requirement?]

I've gone through following link but not succeeded with this.

https://help.openstreetmap.org/questions/9823/how-can-i-select-a-linestring-with-openlayers-selectfeture-at-any-position-of-the-line

asked 25 Nov '13, 10:50

nismeh's gravatar image

nismeh
11112
accept rate: 0%

edited 26 Nov '13, 12:52

NicolasDumoulin's gravatar image

NicolasDumoulin
3.3k42256

How is "create a popup to display information regarding that trajectory/route" related to OSM? What kind of information do you imagine?

(25 Nov '13, 11:56) aseerel4c26 ♦

I also have some problems to understand your request.
So you talk about #OpenLayers and popups. But where is the exact problem in your case? http://wiki.openstreetmap.org/wiki/Openlayers#Examples

(25 Nov '13, 12:25) iii

Let me again try to describe my requirement.

I am displaying route of two different coordinates. Now on my map I am with multiple routes for multiple locations. Now if I am clicking on any of the route, it should show me route information in popup window. for an example my route it from location A to location B is shown in map. Now if I am clicking on this route than it should display information like

Route A- B

Distance X miles

Similar feature is available there on Google Earth. If we are with multiple KMLs and that displays us multiple routes. Now if I am clicking on any of them, than it will display a popup providing differen information about selected route.

(25 Nov '13, 12:45) nismeh
3

You'd be better off asking this question at the support site of whichever web framework you're using to display the data. You've linked to an OpenLayers question - does that mean you're using OpenLayers? If so, you're probably best off starting here:

http://openlayers.org/dev/examples/

(25 Nov '13, 13:09) SomeoneElse ♦

As the other comments, I recommand to you to post your question on specific forum about OpenLayers or Leaflet. For your information, umap may answer your request: http://umap.openstreetmap.fr/fr/

permanent link

answered 26 Nov '13, 07:32

NicolasDumoulin's gravatar image

NicolasDumoulin
3.3k42256
accept rate: 13%

edited 26 Nov '13, 09:26

SomeoneElse's gravatar image

SomeoneElse ♦
36.9k71370866

Hi, Thank You for your suggestion. I want exact thing as follwing link showing.

http://umap.openstreetmap.fr/en/map/gebiete-mit-fehlenden-adressen-in-chemnitz_828#12/50.8301/12.9299

Can you suggest me an approach?

(26 Nov '13, 10:46) nismeh

It depends on the source of you trajectories/routes! In umap, you can import your data as gpx/geojson/kml/osm. So you have to save your trajectories/routes in a file (the format will depend on your source and your tool), and then add them in your umap creation.

(26 Nov '13, 12:50) NicolasDumoulin
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×710
×535
×315
×13

question asked: 25 Nov '13, 10:50

question was seen: 4,266 times

last updated: 26 Nov '13, 12:52

NOTICE: help.openstreetmap.org is no longer in use from 1st March 2024. Please use the OpenStreetMap Community Forum