[Users] formPanel search not working with WFS

John M. Stein jms at clevelandmetroparks.com
Tue Sep 6 22:58:05 CEST 2011


Hello All,
 
I'm trying to set up a very simple search form.  Most of my usergroup
perusals have shown that it seems to be pretty straightforward, but for some
reason this just won't work.  When the search is sent, I recieve (via
Firebug) a GML that, once saved into its own .xml on the server, works
perfectly fine.  For whatever reason, it just doesn't want to show up from
the POST request.
 
Here's the code:
 
 
    formPanel = new GeoExt.form.FormPanel({
        title: "SEARCHBOX",   
        region: "north",     
        width: 300,
        height: 100,
        protocol: new OpenLayers.Protocol.WFS({
              url:  GeoserverWFS,
              version: "1.1.0",
              featureType: "plant_view",
              featureNS: "localparks",
              srsName: "EPSG:3734"                    
              }),
        items: [{
            xtype: "textfield",
            name: "p_genus",
            value: "Acer",
            fieldLabel: "GENUS"
        }, {
            xtype: "textfield",
            name: "p_species",
            value: "saccharinum",
            fieldLabel: "SPECIES"
        }
 ],

    listeners: {
        actioncomplete: function(form, action) {
//   alert(action.response);   
            }
 
    }
});
 
    formPanel.addButton({
        text: "search",
        handler: function() {
            this.search();
        },
        scope: formPanel
    });

 
right?  pretty standard.  I tried WFS 1.0.0. and 1.1.0.  I tried playing
around with WFS settings in GeoServer (changing SRS styles from XML to URN -
which never changes the request..).
 
The important thing is that I'm getting a proper GML Post from the search.
I tried adding a blank vector layer to the eventlistener and adding bindings
from a FeatureDataStore, but those methods failed me as well.  Is there some
basic setting in WFS that I am completely missing?  Might this have to do
with geoserver version (2.1.0)?  
 
Is there anything else I can do with the eventlistener to force a rendering
of the response?  Something with action.response written into a temp.xml and
rendered?  
 
Thanks for any insight..
 
 http://www.clemetparks.com/images/esig/cmp-ms-90x122.pngJohn Stein
Geographic Information Systems (GIS) Intern
(216) 635 3239   [Mon, Tues, Thurs] 

Horticulture Intern

(330) 760 3243   [Wed, Fri]

jms at clevelandmetroparks.com


 

 

 

 

 
 
 http://www.clemetparks.com/images/esig/cmp-ms-90x122.pngJohn Stein
Geographic Information Systems (GIS) Intern
(216) 635 3239   [Mon, Tues, Thurs] 

Horticulture Intern

(330) 760 3243   [Wed, Fri]

jms at clevelandmetroparks.com


 

 

 

 

 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.geoext.org/pipermail/users/attachments/20110906/cc534b2a/attachment.htm 


More information about the Users mailing list