[ka-Map-users] adding layers with MapScript

Paul Spencer pspencer at dmsolutions.ca
Thu May 18 08:08:43 EDT 2006


this is tricky with ka-Map as it is designed around the principle of  
a static map file used as a base layer.  However it is possible.

If you are overlaying points, my first suggestion would be to try  
overlaying them on the client side using the addObjectGeo function.   
The idea here is that you make an ajax call to the server to retrieve  
the point data (x,y,attributes) and then create images to place on  
the map.  This is typically used in a scenario where the user can  
choose to display something in response to some input.

If you really want to create a layer dynamically and render it, you  
will need to modify tile.php.  You will also likely need to set up a  
custom init.php or some javascript to create a _layer



On 18-May-06, at 7:55 AM, E C wrote:

> Hi,
> With a bit of help I've succeeded in putting up a map with ka-map.
> My next step would be to add points dynamically with MapScript
> during the initialization of the map. I've tried to put this  
> unsuccessfully
> in init.php. Could you give me a hint as to how I can proceed? I'm
> new to Ajax so maybe I have missed something conceptually.
> With plain MapServer/MapScript I just built a layer programmatically
> in PHP. How could I accomplish the same thing with Ka-Map/Ajax??
> Thanks,
> Gilles
> _______________________________________________
> ka-Map-users mailing list
> ka-Map-users at lists.maptools.org
> http://lists.maptools.org/mailman/listinfo/ka-map-users

|Paul Spencer                           pspencer at dmsolutions.ca   |
|Applications & Software Development                              |
|DM Solutions Group Inc                 http://www.dmsolutions.ca/|

More information about the ka-Map-users mailing list