[Chameleon] LegendTemplateLayerInfo()

Langlois, Dominic langlois at nrcan.gc.ca
Thu Oct 7 15:17:47 EDT 2004


Hi Robin,

As far as I know, the function LegendTemplateLayerInfo('[leg_layer_name]')
is
available only when you insert the LegendTemplate widget into your html
template.

The various metadata fields populated in the popup by this function are
'extracted' 
from, on my installation, the mapfile more specifically from the LAYER
section and
METADATA subsection for each layer. Here is an excerpt from my mapfile:

  LAYER
    CONNECTION "http://..."
    CONNECTIONTYPE WMS
      METADATA
        "wms_srs" "EPSG:4326 AUTO:42001 AUTO:42002 AUTO:42003 AUTO:42004
EPSG:4269"
        "wms_onlineresource"  "http://..."
        "wms_name"  "CANIMAGE:CANIMAGE/CANIMAGE"
        "wms_formatlist"  "image/png,image/gif,image/jpeg"
        "wms_format"  "image/png"
        "selected"  "0"
        "wms_server_version"  "1.1.1"
        "wms_title" "CANIMAGE"
        "wms_abstract" "CanImage is an image composed of three spectral
bands originating from
         resampled Landsat 7 orthoimages. They are chosen by the user based
on
         the National Topographic System (NTS) at the 1:50 000 scale. This
         product is distributed in GeoTIFF. The spectral bands have a pixel
size
         of 15 m. To order this product, please consult the Centre for
Topographic
         Information at http://ctis.nrcan.gc.ca."
      END
    NAME "CANIMAGE"
    GROUP "Reference Layers"
    SIZEUNITS PIXELS
    STATUS OFF
    TOLERANCE 0
    TOLERANCEUNITS PIXELS
    TYPE RASTER
    UNITS METERS
  END

Hope this will help.


 

Dominic Langlois
Natural Resources Canada
Centre for Topographic Information
Web Services Team
2144 King West Street, s. 010
Sherbrooke, Quebec  J1J 2E8
E-Mail:  langlois at NRCan.gc.ca
Tel:  (819) 564-5600 #267
Fax:  (819) 564-5698 



-----Original Message-----
From: chameleon-bounces at lists.maptools.org
[mailto:chameleon-bounces at lists.maptools.org]On Behalf Of Robin Brown
Sent: Thursday, October 07, 2004 8:40 AM
To: Chameleon
Subject: [Chameleon] LegendTemplateLayerInfo()


Hi all,

In some of the Chameleon samples, in the legend template there is the line
<a href="#"
onclick="javascript:LegendTemplateLayerInfo('[leg_layer_name]');">[metadata
name=WMS_TITLE]</a>

Does anyone know where the "LegendTemplateLayerInfo('[leg_layer_name]')"
function is
found?  I have looked through the various legend widgets but I couldn't find
it.  This
is somewhat of an extension of my question yesterday as I am still trying to
find where
to fill the rest of the fields in the popup that this onclick event creates.
Thanks


Robin

-- 
NB Aquatic Data Warehouse
Canadian Rivers Institute
University of New Brunswick
Hugh John Fleming Forestry Complex
Sir James Dunn Wildlife Research Center
Room 263
1350 Regent Street
Fredericton, NB
E3C 2G6

Phone:    (506) 458-7557
Email:     rbrown at unb.ca
_______________________________________________
Chameleon mailing list
Chameleon at lists.maptools.org
http://lists.maptools.org/mailman/listinfo/chameleon


More information about the Chameleon mailing list