hi Yves,<br><br>You already managed, so just for extra info:<br><br>I
use the OpenLayers.Layer.Text() method. I get info from a sql-database
and make a csv 'file' of it on the fly with php, using echo statements
and tabs (\t) and linebreaks (\n). In addition, the script can take a
category from the url to enable different overlays (
markers.txt.php?overlay=houses, markers.txt.php?overlay=trees, etc.).<br><br>There
are some drawbacks though. Any linebreaks in the description-field will
mess up the csv, for example. Using xml (georss) will be more robust, I
guess, although one must escape html-tags properly, otherwise the
xml-syntax returns errors.<br><br>I chose for csv because it is supported in the current stable version of openlayers. GeoRSS isn't, or is it?<br><br>Robert.<br><br><div><span class="gmail_quote">On 1/5/07, <b class="gmail_sendername">
Yves Jacolin</b> <<a href="mailto:yjacolin@free.fr">yjacolin@free.fr</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Le Vendredi 5 Janvier 2007 14:44, Nick Whitelegg a écrit:<br>> On Friday 05 Jan 2007 13:25, Yves Jacolin wrote:<br>> > Hi,<br>> ><br>> > I am trying to work with OpenLayers. I am a beginer in javascript, sorry
<br>> > for basic questions.<br>> ><br>> > I want to display a different popup for each points. My points come from<br>> > a postgresql DB that I retrieve using AJAX. All informations (lon, lat,<br>
> > icon, html for popup) are in a variable. I am using the code from the<br>> > popups.html examples.<br>> ><br>> > My problem is I can't manage the HTML content for each marker. In the<br>> >
popups.html example, there are one marker and so one content.<br>> ><br>> > Thanks for your answer.<br>> ><br>> > Y.<br>><br>> Hello Yves,<br>><br>> This sounds kind of similar to what I'm doing. If you make your points
<br>> available as a GeoRSS feed, you can use the "GeoRSS2" layer available at<br>><br>> <a href="http://www.free-map.org.uk/test/GeoRSS2.js">http://www.free-map.org.uk/test/GeoRSS2.js</a><br>><br>> which creates markers from a GeoRSS feed.
<br>> There is a load() method which takes a bounding box and loads all markers<br>> in that box.<br>><br>> There is a full example at<br>><br>> <a href="http://www.free-map.org.uk/test/fmap.html">http://www.free-map.org.uk/test/fmap.html
</a><br>><br>> You might want to look at the code for that.<br>><br>> Part of the code is a generic "GeoRSSClient" class which allows the user to<br>> add and remove markers. This is at<br>><br>
> <a href="http://www.free-map.org.uk/test/GeoRSSClient.js">http://www.free-map.org.uk/test/GeoRSSClient.js</a><br>><br>> Let me know if you need more details on any of this.<br>><br>> Nick<br>Hi Nick,<br><br>
Thanks you for your answer. I didn't know that I could use geoRSS.<br><br>Do you think it is possible to manage this using OpenLayers.Layer.Text()<br>method ?<br><br>i.e. retrieve xml, convert it to variable setup like a csv file and send it to
<br>the method above ?<br><br>Thanks,<br><br>Y.<br>--<br>Yves Jacolin<br>---<br>HBS-Research<br>51 rue de Verdun<br>92 158 Suresnes CEDEX<br>Tél. : 01 46 97 25 14<br>Fax : 01 46 97 20 10<br><br>--<br>Yves Jacolin<br>---<br>
<a href="http://yjacolin.gloobe.org">http://yjacolin.gloobe.org</a><br>_______________________________________________<br>Users mailing list<br><a href="mailto:Users@openlayers.org">Users@openlayers.org</a><br><a href="http://openlayers.org/mailman/listinfo/users">
http://openlayers.org/mailman/listinfo/users</a><br></blockquote></div><br><br clear="all"><br>-- <br>Robert Buzink, website ontwerp en ontwikkeling<br>Sint-Pietersaalststraat 123<br>9000 Gent<br>+32 (0)9 33 00 267<br>+32 (0)487 548 414
<br><a href="mailto:post@robertbuzink.nl">post@robertbuzink.nl</a><br><a href="http://robertbuzink.nl/webdesign">robertbuzink.nl/webdesign</a>