Hi Worth: At the moment, you can't get a legend in this case. The legend code isn't smart Enough to discover potential colors and render them. Also, class names cannot be bound to an attribute...
If you really need legends produced by MapServer then attribute binding probably isn't going to work for you. Steve -----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of Worth Lutz Sent: Monday, July 26, 2010 9:27 AM To: [email protected] Subject: [mapserver-users] How do I get a Legend with a variable COLOR in the CLASS I'm trying to set my colors from a postgres table instead of having many classes in my mapfile. Here is an example of what I think I should use to get a legend for this layer. CLASS NAME [name] STYLE COLOR [color] OUTLINECOLOR 0 0 0 WIDTH 1 END END Only the NAME line dies with a parse error as it appears to be looking for a string ([MapServer Error]: getString(): Parsing error near ([name])). It seems that the NAME line cannot take an attribute. How do I get a legend for this layer? Is this the method I should be using for this use? Worth _______________________________________________ mapserver-users mailing list [email protected] http://lists.osgeo.org/mailman/listinfo/mapserver-users _______________________________________________ mapserver-users mailing list [email protected] http://lists.osgeo.org/mailman/listinfo/mapserver-users
