[Chameleon] question about session map file

Julien-Samuel Lacroix jlacroix at mapgears.com
Thu Mar 23 15:32:48 EST 2006


Hi,
I'm not sure what you changed, but the WMSBrowser normally only add one 
layer, not two. You may try to review your changes.

Now to answer to your questions:
1. The session is created by Chameleon. The software has it's own 
session handling. For the mapfile, it is created by MapScript. The code 
is in the wrapper:
chameleon/htdocs/common/wrappers/map_session.php
The code is simply doing a $oMap->save(); soif you have two layers, it 
is probably because you added two of them in the map object in your code.

2. MS4W is only a package to easily install MapServer and related 
products. It does not really contains code by itself. The dll files 
comes from the various MapServer dependancy, not from MS4W itself.

Julien

He, Matt Yubin wrote:
>  
> 
> Hi All:
> 
>            
> 
>             I am using the WMSBrowser widget to add layer. I modified 
> this widget to add group name into the new layer.
> 
> I also modified legend_Template file to group all layers based on their 
> group name (please see below).
> 
> However, when I added a new layer, in the session map file 
> (C:/ms4w/tmp/sess_[session_id]/[unique_id].map), there are two identical 
> layers added.  I am trying to figure out why two layers were added into 
> session map file instead of one.
> 
>  
> 
> Could some one tell me: 1. how session map file was generated? Is it by 
> Chameleon, or by Mapserver code, or by MS4W code?
> 
> 2. is MS4W code open source? There are some dll files, where to get source?
> 
>  
> 
> Thank you very much.
> 
>  
> 
> Matt
> 
>  
> 
>  
> 
> [leg_group_html]
> 
> </ul></li>
> 
> <li><table><tr><td width="100" 
> class="menutitle">[leg_group_name]</td></tr></table>
> 
>    <ul>
> 
> [/leg_group_html]
> 
>  
> 
> [leg_layer_html order=ascending opt_flag=15]
> 
> <li>
> 
>   <table>
> 
>   <tr bgcolor="#ffffff">
> 
>     <td><input type="radio" name="my_legend" 
> onclick="CWCSelectLayer('[leg_layer_name]', true)"[if name=selected 
> value=1] CHECKED[/if] ></td>
> 
>     <td align="center" width=20><input type="checkbox" 
> name="legendlayername[]" value="[leg_layer_name]"
> 
>     [if name=layer_status oper=eq  value=1]CHECKED[/if]
> 
>     [if name=layer_status oper=eq value=2]CHECKED[/if]></td>
> 
>     <td><img src="[leg_icon width=20 height=18]" width="20" height="20"</td>
> 
>     [if name=wms_name oper=isnull]
> 
>     <td><a href="#" 
> onclick="javascript:LegendTemplateLayerInfo('[leg_layer_name]');"><span 
> class="label">[leg_layer_name]</span></a></td>
> 
>   </tr>
> 
>     [/if]
> 
>     [if name=wms_name oper=isset]
> 
>     <td><a href="#" 
> onclick="javascript:LegendTemplateLayerInfo('[leg_layer_name]');"><span 
> class="label">[metadata name=WMS_TITLE]</span></a></td>
> 
>   </tr>
> 
>     [/if]
> 
>   </table>
> 
> </li>
> 
> [/leg_layer_html]
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> Chameleon mailing list
> Chameleon at lists.maptools.org
> http://lists.maptools.org/mailman/listinfo/chameleon

-- 
Julien-Samuel Lacroix
Mapgears
http://www.mapgears.com/


More information about the Chameleon mailing list