[mapserver-users] getProjection error

Bistrais, Bob Bob.Bistrais at maine.gov
Tue Sep 4 12:12:02 PDT 2012


I have a map layer that I want to do a simple query-by-point with.  Everything look OK and other, similar layers in the project work fine, but when I try to query this particular layer, I get the following error message:

Fatal error: Call to a member function getProjection() on a non-object in C:\ms4w_304\apps\basemap\htdocs\php\select.php on line 213

These are the lines of code in the php file:
                $projection = $map->getProjection();
                if($layer->getProjection() != NULL) {

This is the section of the .map file for the layer:

 LAYER
    NAME 'GeoLibrary_1ft_2003_2005'
    GROUP 'GeoLibrary_1ft_2003_2005'
    DATA "/mapserver_data/basemap/ortho1f/ortho1f_index.shp"
    STATUS on
    TYPE polygon
    TRANSPARENCY 50
    METADATA
      "opacity" "50"
      "queryable" "True"
      "DESCRIPTION" "Geolibrary 1ft index"
      "SEARCHFIELD" "tile"
      "fields" "tile:tilename,location,link"
      "hyperlink" "link"
      "wms_title" "Geolibrary 1ft Index"
  "wms_srs" "EPSG:26919"
      'identify_record' 'templates/identify_geolib.html'
      'select_record' 'templates/ortho_result.html'
      'select_header' 'templates/ortho_header.html'
    END

---There is a CLASS section below this for the symbology.

-As I said, other, similar layers are working just fine with the same query code, and I can't see anything wrong with the shapefile.  What else should I be checking?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20120904/ad9d82b6/attachment.htm>


More information about the MapServer-users mailing list