Gabriel Roldán ha scritto:
> Hi Andrea,
> 
> was playig with it for a while and seems certainly very useful.
> 
> One usefull feature to add would be ability to select the style to apply. 
> Though I realize it would be not that easy as may require capabilities 
> parsing and we know what happens with the huge list of crs's.

Ah, no, there is no need in fact. Since the preview is generated by 
server side code using a freemarker template, I can access the feature
type configuration, grab a list of styles and use them to fill the drop
down list, all on the server side (no caps parsing required).

Hmm... but no, this won't work either... the problem is that the OL
preview can be filled with as many layers as you want, it's just an 
output format anyways. Maybe some options could be made available
only if the context is right.
For example, style dropdown only if there is a single layer (which is 
not a layer group).

> Tip: to make it work with ports other than 8080 and contexts other 
> than /geoserver its only needed to use relative urls (current preview page 
> suffers from the same defect).
> To do so, just change any occurrence of "http://localhost:8080/geoserver/wms"; 
> by "../wms", and "http://localhost:8080geoserver/openlayers/OpenLayers.js"; 
> by "openlayers/OpenLayers.js"

Hmmm... yeah. Thought this would make it harder to move the page around 
to other locations (think save and drop in www or drop into your apache
server and so on). I can centralize the geoserver root in one js 
variable so that one does not have to change the base url in multiple 
places.

Cheers
Andrea

-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference 
Don't miss this year's exciting event. There's still time to save $100. 
Use priority code J8TL2D2. 
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
_______________________________________________
Geoserver-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-devel

Reply via email to