and here's an excellent beginner doc: http://mapserver.gis.umn.edu/docs/howto/phpmapscript-byexample

jeff




blaise wrote:
On Monday 06 March 2006 20:40, VolComHG (sent by Nabble.com) wrote:

Im new with mapscript and i learn how to use it
Here my code
<?php

if (!extension_loaded("MapScript")) dl('php_mapscript_46.dll');
$map_path="C:/ms4w/apps/kamap-0.1.1/htdocs/";
$map = ms_newMapObj($map_path."global.map");
$image=$map->draw();
$image_url=$image->saveWebImage();


?>

<HTML>
 <HEAD>
     <TITLE>Essaie</TITLE>
 </HEAD>
 <BODY>
     <?php  >
 </BODY>
</HTML>

When I open the html page it said :

draw(); $image_url=$image->saveWebImage(); ?>  >

I think it doesnt recognize the mapscript   sorry for my english

Someone can help me plz !!!!


Have a look at this doc :
http://mapserver.gis.umn.edu/docs/howto/phpmapscript-install/?searchterm=phpinfo
particularly 2.4.1 :
. . . 2.4.1 Using phpinfo() To verify that PHP and PHP/Mapscript were installed properly, create a '.php' file containing the following code and try to access it through your web server:
<HTML>
<BODY>

<?php if (PHP_OS == "WINNT" || PHP_OS == "WIN32")
  {
    dl("php_mapscript.dll");
  }
  else
  {
    dl("php_mapscript.so");
  }
  phpinfo();
?>

</BODY>
</HTML>

If PHP and PHP/Mapscript were installed properly, several tables should be displayed on your page, and 'Mapscript' should be listed in the 'Extensions' table.
. . .
Do you see Mapscript in this php page ? (Be sure to put the right name for the mapscript dll : php_mapscript.dll, or php_mapscript_46.dll, or else...)
Blaise



--
Jeff McKenna
DM Solutions Group Inc.
http://www.dmsolutions.ca

Reply via email to