<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META content="text/html; charset=iso-8859-1" http-equiv=Content-Type>
<META name=GENERATOR content="MSHTML 8.00.6001.18702"></HEAD>
<BODY 
style="WORD-WRAP: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space">
<DIV dir=ltr align=left><FONT color=#0000ff size=2 face=Arial><SPAN 
class=349415606-08102009>Hello Rick, thanks for your response and sorry for the 
lack of information, I didn't know how to start asking. I've seen all WFS 
related OL examples. For instance, in the example of selecting features from wfs 
which uses&nbsp;OpenLayers.Protocol.WFS.fromWMSLayer, it doesn't appear to be a 
good solution for me, because it makes me to have the same layers for WMS and 
for WFS. So then I tried another way: </SPAN></FONT></DIV>
<DIV><FONT color=#0000ff size=2 face=Arial><SPAN 
class=349415606-08102009></SPAN></FONT>&nbsp;</DIV>
<DIV><FONT color=#0000ff size=2 face=Arial><SPAN class=349415606-08102009>var 
recintosLayer = new 
OpenLayers.Layer.Vector("WFS",<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{strategies: 
[new OpenLayers.Strategy.BBOX()],<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;protocol: new 
OpenLayers.Protocol.WFS({<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
url:&nbsp; "<A 
href="http://192.168.1.65/cgi-bin/mapserv.exe?map=../htdocs/MFD/ejemplo_wfs.map">myurl</A>",<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
featureType: 
"RecintosSigpac",<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
featureNS: "<A 
href="http://192.168.1.65/cgi-bin/mapserv.exe?map=../htdocs/MFD/ejemplo_wfs.map">myurl</A>",<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
srsName: 
"EPSG:23030",<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
version: "1.1.0",&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</SPAN></FONT></DIV>
<DIV><FONT color=#0000ff size=2 face=Arial><SPAN 
class=349415606-08102009></SPAN></FONT>&nbsp;</DIV>
<DIV><FONT color=#0000ff size=2 face=Arial><SPAN class=349415606-08102009>but, 
as I have over a million features stored in that table,&nbsp;I try to load the 
page, but it takes a lot of time and furthermore it never loads the geometries. 
So I decided not to implement that solution and try another way. Now I'm on my 
3rd attempt to solve this problem. </SPAN></FONT></DIV>
<DIV><FONT color=#0000ff size=2 face=Arial><SPAN 
class=349415606-08102009></SPAN></FONT>&nbsp;</DIV>
<DIV><FONT color=#0000ff size=2 face=Arial><SPAN class=349415606-08102009>At the 
moment I'm trying to do the same by using the folowing idea:</SPAN></FONT></DIV>
<DIV><FONT color=#0000ff size=2 face=Arial><SPAN 
class=349415606-08102009></SPAN></FONT>&nbsp;</DIV>
<DIV><FONT color=#0000ff size=2 face=Arial><SPAN class=349415606-08102009>Using 
GetFeatureInfo, get the geometry from the x,y clicked by the user. Then add that 
feature to a vector layer on the fly, and then highlight it on UI. Later it 
would be perfect if I manage to interact with them. I'm developing it and I 
think that I'll be able (I hope!!!) to do it in this way, but what I'm wondering 
is if this is the best way to do things. Is there another easier way to do 
things?Isn't there an OL function that does what I want to 
do?</SPAN></FONT></DIV>
<DIV><FONT color=#0000ff size=2 face=Arial><SPAN 
class=349415606-08102009></SPAN></FONT>&nbsp;</DIV>
<DIV><FONT color=#0000ff size=2 face=Arial><SPAN class=349415606-08102009>Thanks 
again.</SPAN></FONT></DIV>
<DIV><FONT color=#0000ff size=2 face=Arial></FONT>&nbsp;</DIV><BR>
<DIV dir=ltr lang=es class=OutlookMessageHeader align=left>
<HR tabIndex=-1>
<FONT size=2 face=Tahoma><B>De:</B> users-bounces@openlayers.org 
[mailto:users-bounces@openlayers.org] <B>En nombre de </B>Rick 
Wayne<BR><B>Enviado el:</B> miércoles, 07 de octubre de 2009 
17:56<BR><B>Para:</B> users@openlayers.org<BR><B>Asunto:</B> [OpenLayers-Users] 
Re: Select features from wfs layer<BR></FONT><BR></DIV>
<DIV></DIV>
<BLOCKQUOTE type="cite">I'd like to develope a functionallity that allows the 
  user to select some of that features (by selecting I mean that I'd would like 
  to have them highlighted) and get some info about them. I've been seaching on 
  the web and I found some ways of doing that, but I don't know if are the 
  correct way of doing things.</BLOCKQUOTE><BR>
<DIV>Hullo David,</DIV>
<DIV><BR></DIV>
<DIV>You'll probably have to provide a little more detail. You have examined the 
"examples" page (<A 
href="http://www.openlayers.org/dev/examples/">http://www.openlayers.org/dev/examples/</A>), 
right? If you right-click on the map frame and view the frame source, you can 
look at the ones which do click handlers and provide info about the feature 
clicked on, using e..g GetFeatureInfo.</DIV>
<DIV><BR></DIV>
<DIV>rw</DIV>
<DIV><BR></DIV>
<DIV><BR></DIV></BODY></HTML>