PHP/MapScript getShape() failing with an index returned by getResult() - PostGIS layer

Daniel Morissette dmorissette at MAPGEARS.COM
Tue Feb 27 09:34:57 PST 2007


Doug B wrote:
> 
> Hmmm... interestingly, I'm seeing some significant differences between
> the API documentation at
> http://mapserver.gis.umn.edu/docs/reference/mapscript and at
> http://mapserver.gis.umn.edu/docs/reference/phpmapscript-class/classes/layerobj 
> 

The SWIG MapScript (Perl, Python, etc.) and PHP MapScript differ a 
little bit. Since you're using PHP MapScript you should always work with 
the PHP MapScript docs.


> .  The former says getShape() was deprecated at 4.4 and shows an
> entirely different method signature:
> 
> getShape( shapeObj shape, int tileindex, int shapeindex ) : int
> 
> vs.
> 
> shapeObj getShape(int tileindex, int shapeindex)
> 
> Do I have to use the former syntax now with my post 4.4 MapServer?
> 

With PHP MapScript you should use:

shapeObj getShape(int tileindex, int shapeindex)

Daniel
-- 
Daniel Morissette
http://www.mapgears.com/



More information about the MapServer-users mailing list