An other example using a vector layer, information displayed in a popup using a custom control "Hover". (click the "edit" button to see the popups):
http://dev4.mapgears.com/bdga-mapfish/ Best of luck, Alexandre Rahn Hanno (rahn) wrote: > > Hello list, > > I have some questions about the mousemove event and mousePosition > control. In Openlayers it ist possible to show the coordinates of the > mousposition in the lower right of the map for example how you can see > in the image. > > The text will dynamically change if you are moving the mouse of > course. I realised it like this: > > map.addControl(new OpenLayers.Control.MousePosition()); > > map.events.register("mousemove", map, function(e) { > > }); > > And now my question. I want to get the name of the region if I get > over the map. If I move the mouse over the map, the text in the lower > right should show the name of the right region instead of the > coordinates. The names are saved in a postgis database. I hope you > understand what I will do, because my english ist not very well and > somebody can help me. I tried it so long, but I didn’t find a > solution. Perhaps somebody had already realised it and can give me > some tipps and help. For your help a lot of thanks. I hope it will be > possible. > > Greetings > > Hanno Rahn > > ------------------------------------------ > > Hanno Rahn, Dipl.-Ing. (FH) Geoinformatik > > ZHAW Zürcher Hochschule für Angewandte Wissenschaften Umwelt und > Natürliche Ressourcen > > Fachstelle Geoinformatik > > Grüental, Postfach CH-8820 Wädenswil > > Tel +41 (0)58 934 5592 > > Fax +41 (0)58 934 5580 > > [email protected] > > ------------------------------------------------------------------------ > > _______________________________________________ > Users mailing list > [email protected] > http://openlayers.org/mailman/listinfo/users > -- Alexandre Dubé Mapgears www.mapgears.com _______________________________________________ Users mailing list [email protected] http://openlayers.org/mailman/listinfo/users
