[OpenLayers-Users] FramedCloud GEORSS support

Christopher Schmidt crschmidt at metacarta.com
Wed Apr 2 07:47:36 EDT 2008


On Wed, Apr 02, 2008 at 12:33:34PM +0800, David Martin wrote:
> I have been following the development around FramedClould for the last
> few days and now see that it is published in the trunk. Excellent piece
> of work to all concerned.
>
> I cannot profess to be a JS expert nor am I fully into OL code as yet -
> I am getting there but thought it best to ask this question before I
> start adjust the code. Is it possible to transfer support of the GEORSS
> markers from popup to FramedCloud popups. This would sit closer to other
> implementations. 

What 'other implementations'?

> Maybe there is a simple way to do this however as I
> stated I am not fully into it just yet.

So, I have a couple feelings on this. 

1. The way that we do Layer.GeoRSS right now is an unfortunate
   situation: if we were to 'do it all over again', we would do it very
   similar to the new examples/sundials.html, by having a single layer
   that wrapped up the data display and a selectfeature control to open
   a popup. I *highly* recommend looking at this example: It's a few
   more lines of code than setting up a layer.GeoRSS, but it's *way*
   more extensible, since you have complete control over just about
   everything.

2. If you don't like this, and want to use layer.georss with
   framedclouds, then you can do this at this time:

    OpenLayers.Feature.prototype.popupClass =
      OpenLayers.Popup.FramedCloud;

   I think this should work as a first order approximation. However,
   there could be problems with this, and it's not really 'supported'
   because we don't do it in our tests or examples, so it is, at the
   moment, somewhat at your own risk.

I still recommend #1 strongly for anyone doing work with GeoRSS for the
long term -- your next question will be "how do I use different icons
for entries from different categories?", and that one can't be answered
nearly so easily.

Good luck, and Best Regards,
-- 
Christopher Schmidt
MetaCarta



More information about the Users mailing list