Please help: cannot use function "mssavemapcontext"

Xiongjiu Liao xliao at MIT.EDU
Fri Nov 26 18:03:29 EST 2004


Hello, everyone:
  I am working on a project with Mapserver, but I meet some problems with it,
would you please give some ideals? Really appreciate it.

##############
  a) here is my Mapserver configure output:
 ./mapserv40 -v
MapServer version 4.2.5 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP
SUPPORTS=PROJ SUPPORTS=FREETYPE SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT
SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT INPUT=EPPL7 INPUT=OGR INPUT=GDAL
INPUT=SHAPEFILE

#################
  b) here is the php program I want to test:
    <?php
      dl("php_mapscript.so");
      $oMap = ms_newMapObj("/www/htdocs/tutorial/context_test1.map");
      $oMap->saveMapContext("gmap_wms_context_output.xml");
    ?>


###########################
c)  here is the error message:

Warning: [MapServer Error]: msSaveMapContext(): Not implemented since Map
Context is not enabled. in /www/htdocs/context_script.php on line 4

Warning: Failed saving map context from gmap_wms_context_output.xml in
/www/htdocs/context_script.php on line 4


#############################
d) here is my mapfile:

  Map
  NAME EX3.1_
  status on
  PROJECTION
     "init=epsg:2163"
  END

web
  IMAGEPATH '/www/htdocs/tutorial/data/tmp/'
  IMAGEURL '/tutorial/data/tmp/'
  METADATA
      "WMS_TITLE" "UMN MapServer Upper Great Lakes Application"
      "WMS_ONLINERESOURCE"
"http://localhost/cgi-bin/mapserv40?map=context_test1.map&"
      "WMS_SRS"  "EPSG:2163 EPSG:4326 EPSG:26915 EPSG:26916"
  END
end

   LAYER
     NAME         states
     DATA         states_ugl
     STATUS       DEFAULT
     TYPE         POLYGON
     METADATA
       "wms_title" "Elevation/Bathymetry"
       "wms_srs"   "EPSG:42304 EPSG:4269 EPSG:4326"
     END
     #CONNECTIONTYPE WMS
     #CONNECTION
"http://www2.dmsolutions.ca/cgi-bin/mswms_gmap?#VERSION=1.1.0&LAYERS=bathymetry&FORMAT=image/png"
    # PROJECTION
     #  "init=epsg:42304"
     #END
    END

end

##############################


  Thank you very much!
  Happy Thksgiving!



More information about the mapserver-dev mailing list