<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.2800.1106" name=GENERATOR></HEAD>
<BODY>
<DIV dir=ltr align=left><SPAN class=343183416-03052010><FONT face=Arial 
color=#0000ff size=2>Hi Paul,</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=343183416-03052010><FONT face=Arial 
color=#0000ff size=2></FONT></SPAN>&nbsp;</DIV>
<DIV dir=ltr align=left><SPAN class=343183416-03052010><FONT face=Arial 
color=#0000ff size=2>SLD_BODY is a request parameter of a wms. If you can get 
from your grid a reference to your OpenLayers WMS layer, then you can use 
</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=343183416-03052010><FONT face=Arial 
color=#0000ff size=2></FONT></SPAN>&nbsp;</DIV>
<DIV dir=ltr align=left><SPAN class=343183416-03052010><FONT face=Arial 
color=#0000ff size=2>yourWMSlayer.mergeNewParams('SLD_BODY' : 
....).</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=343183416-03052010><FONT face=Arial 
color=#0000ff size=2></FONT></SPAN>&nbsp;</DIV>
<DIV dir=ltr align=left><SPAN class=343183416-03052010><FONT face=Arial 
color=#0000ff size=2>if your wms have only one layer (in the eample below 
POLYGONS) to request, you can use something like this</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=343183416-03052010><FONT face=Arial 
color=#0000ff size=2></FONT></SPAN>&nbsp;</DIV>
<DIV dir=ltr align=left><SPAN class=343183416-03052010><FONT face=Arial 
color=#0000ff size=2>&lt;StyledLayerDescriptor version="1.0.0" xmlns="<A 
href="http://www.opengis.net/sld">http://www.opengis.net/sld</A>" xmlns:gml="<A 
href="http://www.opengis.net/gml">http://www.opengis.net/gml</A>" xmlns:ogc="<A 
href="http://www.opengis.net/ogc">http://www.opengis.net/ogc</A>" 
xmlns:xlink="<A 
href="http://www.w3.org/1999/xlink">http://www.w3.org/1999/xlink</A>" 
xmlns:xsi="<A 
href="http://www.w3.org/2001/XMLSchema-instance">http://www.w3.org/2001/XMLSchema-instance</A>" 
xsi:schemaLocation="<A 
href="http://www.opengis.net/sld">http://www.opengis.net/sld</A> <A 
href="http://schemas.opengis.net/sld/1.0.0/StyledLayerDescriptor.xsd">http://schemas.opengis.net/sld/1.0.0/StyledLayerDescriptor.xsd</A>"&gt;<BR>&lt;NamedLayer&gt;<BR>&lt;Name&gt;COUNTRY&lt;/Name&gt;<BR>&lt;UserStyle&gt;<BR>&lt;FeatureTypeStyle&gt;<BR>&lt;Rule&gt;<BR>&lt;PolygonSymbolizer&gt;<BR>&lt;Fill&gt;<BR>&lt;CssParameter 
name="fill"&gt;#f0f0f0&lt;/CssParameter&gt;<BR>&lt;CssParameter 
name="fill-opacity"&gt;1.00&lt;/CssParameter&gt;<BR>&lt;/Fill&gt;<BR>&lt;Stroke&gt;<BR>&lt;CssParameter 
name="stroke"&gt;#646464&lt;/CssParameter&gt;<BR>&lt;/Stroke&gt;<BR>&lt;/PolygonSymbolizer&gt;<BR>&lt;/Rule&gt;<BR>&lt;/FeatureTypeStyle&gt;<BR>&lt;/UserStyle&gt;<BR>&lt;/NamedLayer&gt;<BR>&lt;/StyledLayerDescriptor&gt;</FONT></SPAN></DIV>
<DIV>&nbsp;</DIV>
<DIV dir=ltr align=left><SPAN class=343183416-03052010><FONT face=Arial 
color=#0000ff size=2>as SLD_BODY to highlight the the features of the layer. 
Attention! You have to delete the line feeds for the request. 
</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=343183416-03052010><FONT face=Arial 
color=#0000ff size=2></FONT></SPAN>&nbsp;</DIV>
<DIV dir=ltr align=left><SPAN class=343183416-03052010><FONT face=Arial 
color=#0000ff size=2>Zooming to the extent of the wms layer is not so easy, 
perhaps inpossible. You can request the WMS GetCapabilities and hope that there 
the correct extent are described for the layer. Or if the layer is also 
requestable as WFS you can perhaps on that way get the extent of the layer. But 
I'm not sure.</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=343183416-03052010><FONT face=Arial 
color=#0000ff size=2></FONT></SPAN>&nbsp;</DIV>
<DIV dir=ltr align=left><SPAN class=343183416-03052010><FONT face=Arial 
color=#0000ff size=2>If you are the holder of the WMS server, I would suggest, 
that you calculate the extent on other ways and&nbsp;adds&nbsp;it as array to 
your application.</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=343183416-03052010></SPAN>&nbsp;</DIV>
<DIV dir=ltr align=left><SPAN class=343183416-03052010><FONT face=Arial 
color=#0000ff size=2>Arnd</FONT>&nbsp;</SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=343183416-03052010><FONT face=Arial 
color=#0000ff size=2></FONT></SPAN><SPAN class=343183416-03052010><FONT 
face=Arial color=#0000ff size=2></FONT></SPAN>&nbsp;</DIV>
<DIV dir=ltr align=left>
<HR tabIndex=-1>
</DIV>
<DIV dir=ltr align=left><FONT face=Tahoma size=2><B>Von:</B> Paul james 
[mailto:pauljame@gmail.com] <BR><B>Gesendet:</B> Montag, 3. Mai 2010 
16:39<BR><B>An:</B> Arnd Wippermann<BR><B>Cc:</B> fsalas; 
users@openlayers.org<BR><B>Betreff:</B> Re: [OpenLayers-Users] HELP!!! How 
implement Filter in WMS Layer<BR></FONT><BR></DIV>
<DIV></DIV>
<DIV>Hi Arnd...<BR>I have some questions about that...<BR><BR>First I have a geo 
app using Openlayers/Mapserver WMS with SDE layers....<BR>My application has a 
treeview with all layers, and a radiobox for each layer... When I click in a 
layer´s radiobox a window with a GRID containing all layer´s data is 
opened...<BR>In that GRID, When I select a line (layer´s data), the Map should 
:<BR>&nbsp;1-) Highlight it <BR>&nbsp;2-) Zoom in data selected<BR><BR>Can I 
develope that using SLD and SLD_BODY ? Do you have any tip to how do 
that?<BR><BR>Thanks<SPAN class=343183416-03052010><FONT face=Arial color=#0000ff 
size=2>&nbsp;</FONT></SPAN></DIV></BODY></HTML>