processlegendtemplate()

Daniel Morissette dmorissette at MAPGEARS.COM
Fri Mar 23 15:43:19 EDT 2007


I had a look in the code, and it seems that ProcessLegendTemplate() 
doesn't make much use of the parameters array.

You could possibly file a enhancement bug about this.

Daniel

Harri Kiiskinen wrote:
> Hello all, 
> 
> I'm having a problem with the processlegendtemplate(array) in PHP/Mapcript.
> According to the documentation, it should accept a similar parameter array
> as processtemplate(arraý, bool). However, it seems, that while
> processtemplate() does do the replacements from the array,
> processlegendtemplate() does not. Example:
> 
> In php:
>     $template_params["program"]=$_SERVER['PHP_SELF'];
>     echo $map->processtemplate($template_params,MS_TRUE);
>     $ltemplate_params["lprogram"]=$_SERVER['PHP_SELF'];
>     echo $map->processlegendtemplate($ltemplate_params);
> 
> In template_map:
>   <form method="post" action="[program]">
> 
> In template_legend:
>   [leg_header_html]
>   <form method="post" action="[lprogram]">
>   [/leg_header_html]
> 
> In resulting html, for the map template:
> <form method="post" action="/~harri/nemi/nemidb/map_general.php">
> 
> and for the legend template:
> <form method="post" action="[lprogram]">
> 
> Might be I have misunderstood the documentation, but at least the
> PHP/Mapscript documentation indicates, that this should work.
> 
> Greetings,
> 
> Harri K.


-- 
Daniel Morissette
http://www.mapgears.com/



More information about the mapserver-users mailing list