client-side image map

Hunter, David - St. Louis Park, MN David.Hunter at FNF.COM
Tue Jul 12 10:42:40 PDT 2005


I'd like to add a client-side image map for a layer of point features.
I found the documentation for this in the wiki, and it basically works,
except the '%s' variable gets replaced with the layer name.  How can I
write out the contents of a field, for instance each point's name,
instead of the layer name?  

 

This is line from the output:

 

<area href="alert('FireStations');" onMouseOver="return
overlib('FireStations');" onMouseOut="return nd();" shape="circle"
coords="130,238, 3" />

 

This is what my .map file looks like:

 

MAP

OUTPUTFORMAT

  NAME imagemap

  DRIVER imagemap

  MIMETYPE "text/html"

  FORMATOPTION "SYMBOLHREF=alert('%s');"

  FORMATOPTION "MAPNAME=stations"

  FORMATOPTION "SYMBOLMOUSEOUT=return nd();"

  FORMATOPTION "SYMBOLMOUSEOVER=return overlib('%s');"

END

 

EXTENT         -80.2204 35.8442 -79.7739 36.1308

SIZE           670 536

UNITS DD

  

PROJECTION

  "init=epsg:4267"

END

 

 

  # fire stations

  LAYER 

    NAME         "FireStations"

    CONNECTIONTYPE OGR

    CONNECTION "FD/NC0505AFS.tab"

    STATUS       DEFAULT

    TYPE         POINT

    

    PROJECTION

      "init=epsg:4267"

    END

 

    CLASS

      COLOR 0 0 0

    END

  END 

 

END

 

David S. Hunter
Sr. Software Engineer
Fidelity National Geographic Solutions
division of Fidelity National Financial
5353 Gamble Drive, Suite 201
St. Louis Park, MN 55416
* Email: david.hunter at fnf.com
' Phone: 952.542.1440 ext. 256
* Fax: 952.542.3859

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20050712/1baad047/attachment.htm>


More information about the MapServer-users mailing list