[OpenLayers-Users] GeoRSS and Custom Icons

Andreas Hocevar andreas.hocevar at gmail.com
Wed Jun 25 04:33:08 EDT 2008


Hi,

On Tue, Jun 24, 2008 at 11:59 PM, Eric Lemoine <eric.c2c at gmail.com> wrote:
> On Wed, Jun 11, 2008 at 10:22 AM, Levii Smith <smithlev at levii.com> wrote:
> If I were you I wouldn't use Layer.GeoRSS. Instead I would trigger my
> own Ajax request to get the GeoRSS document, use Format.GeoRSS to
> unserialize the GeoRSS doc into features, and add the resulting
> features to a simple vector layer (Layer.Vector). And I would rely on
> OpenLayers' styling framework to style the features based on their
> attributes. See the georss-flickr.html example which more or less does
> this.

In OpenLayer 2.6 you can also use OpenLayers.Layer.GML with an option
format: OpenLayers.Format.GeoRSS. That will issue the Ajax request,
create features from the response and add those to the layer. I just
modified the georss-flickr example to make use of that, which saves
some amount of custom code.

Regards,
Andreas.



More information about the Users mailing list