I thought I could use WFS to get all the features of the polygon layer then use OpenLayers.Format.GML.parseGeometry.multipolygon to turn it into a polygon object in OL. Then I could use OpenLayers.Geometry.Polygon.containsPoint to test if the point is within the polygon. First Question: is this logic sound?
Yes, it is sound and also easy to implement. But you may have an issue if it's more than a few thousand vertices. You may hang the browser simply parsing the GML.
The server-side method you are already attempting, sounds like your best bet. I'm sorry I have no help for you on the hanging problem.
-- Greg Allensworth, Web GIS Developer BS A+ Network+ Security+ Linux+ Server+ GreenInfo Network - Information and Mapping in the Public Interest 564 Market Street, Suite 510 San Francisco CA 94104 PH: 415-979-0343 x302 FX: 415-979-0371 email: [email protected] Web: www.GreenInfo.org www.MapsPortal.org Subscribe to MapLines, our e-newsletter, at www.GreenInfo.org _______________________________________________ Users mailing list [email protected] http://lists.osgeo.org/mailman/listinfo/openlayers-users
