[Chameleon] KeyMap question

Sears, Jeremy Jeremy.Sears at CCRS.NRCan.gc.ca
Fri Jan 27 13:45:13 EST 2006

Hi Paul,
I am picking over 'drawmap.php'. There is a function defined in drawmap.php
that is also called in drawmap.php named 'DrawKeyMap()'. Near the end of the
function are the following lines:

/* -------------------------------------------------------------------- */
/*      draw the image and output it.                                   */
/* -------------------------------------------------------------------- */
      //  $imgObj = $oMapSession->oMap->drawReferenceMap();

      //  $szWebImage = $imgObj->saveWebImage();

...(lines 1408 thru 1413)...

You have to excuse me but Im in the process of learning php. It appears to
me that by uncommenting the two lines there, the keymap should be created
($imgObj) and the location of the keymap should be then stored in

I have uncommented the two lines however I dont see the keymap image in my
tmp folder. Also, it would seem that nothing gets written to the $szwebImage

Have I overlooked other parts of drawmap.php that are relavent to my task?
Why does uncommenting the two above mentioned lines of code seemingly have
no effect?


-----Original Message-----
From: Paul Spencer [mailto:pspencer at dmsolutions.ca]
Sent: January 27, 2006 12:16 PM
To: Sears, Jeremy
Cc: 'chameleon at lists.maptools.org'
Subject: Re: [Chameleon] KeyMap question

Jeremy, the image is returned from drawmap.php.  You can modify  
drawmap.php to save the image as well as/instead of just returning it.



On 27-Jan-06, at 12:03 PM, Sears, Jeremy wrote:

> Good Day All,
> Im wondering how one would go about coaxing chameleon to produce a  
> keymap
> image on disk. I've been looking around in the KeyMap, KeymapDHTML and
> KeymapDHTMLmode widgets for a means to do this but nothing is  
> jumping out at
> me.
> Ideally, an image of my keymap would be produced the same manner  
> that the
> image of my scalebar is produced.
> It looks to me that the keymap widgets create the image on the fly  
> via calls
> to mapserver, and don't actually store the image.
> Can anyone offer general or specific steps I should consider to  
> accomplish
> this?
> Thanks
> Jeremy
> _______________________________________________
> Chameleon mailing list
> Chameleon at lists.maptools.org
> http://lists.maptools.org/mailman/listinfo/chameleon

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

More information about the Chameleon mailing list