[Mapserver-users] HELP PLEASE URGENT!!, draw point in map

Ezequiel Bertone ezeklinux at yahoo.com.ar
Mon Jan 12 17:43:59 EST 2004


Hello

I need draw a point in the map in coordinates XY. 
The problem is that only draw the map without the
point. Where is the problem?
The coordinates XY is correct?

Thank you for you help.

I have the following map file an php file.
---- Php file
<?php
dl('php_mapscript.so');
$map_path="/var/www/html/";
$map=ms_newMapObj($map_path. "easu4.map");

$testlayer = $map->getLayerByName("reddot");
      $testlayer->set("status", 1);
$testpt = ms_newPointObj();
$testpt->setXY(431,7195);

 $image=$map->draw();
      $testpt->draw($map, $testlayer, $image, 0, " ");
$image=$map->draw();
$image_url=$image->saveWebImage(MS_PNG,1,1,0);
?>

<HTML>
<HEAD>
<TITLE>Esto es una prueba de Mapas </TITLE>
</HEAD>
<BODY>
<img SRC=<?php echo $image_url; ?>> 
</BODY>
</HTML>


-- Map file
MAP
  IMAGETYPE      JPEG
  EXTENT         430.0622899324  7194.39117490898 449.
 418992570303 7210.068359375
  SIZE          1200 1200
  SHAPEPATH      "data"
  IMAGECOLOR     255 255 255

  PROJECTION
    "proj=utm"
    "ellps=clrk66"        
    "datum=WGS84"
  END

  # Start of LAYER DEFINITIONS
---------------------------------------------

SYMBOL
   NAME "circle"
   TYPE ellipse
   FILLED true
   POINTS
     1 1 1
   END
END

LAYER
   NAME "reddot"
   TYPE POINT
   STATUS off
   CLASS
     Name "reddot2"
     COLOR 255 0 0
     SYMBOL "circle"
     SIZE 40
   END  # CLASS
END  # LAYER

LAYER # States polygon layer begins here
    NAME         au01
    DATA         asu01
    STATUS       DEFAULT
    TYPE         LINE
    CLASS
      COLOR        0 0 0
      OUTLINECOLOR 32 32 32
    END
END # States polygon layer ends here

END # end of map file/object

------------
Los mejores usados y las más tentadoras 
ofertas de 0km están en Yahoo! Autos.
Comprá o vendé tu auto en
http://autos.yahoo.com.ar



More information about the mapserver-users mailing list