[mapserver-users] label encoding problem

王连波 happyforev1 at gmail.com
Wed Oct 21 05:33:28 PDT 2009


I use mapserver5.4.0 on FreeBSD Release7.1. In my mapfile I get data from
postgis database whose encoding is EUC_CN, and my label part go as follows:
     labelitem name
     CLASS
        NAME    xzqj_x
        STYLE
        color         255 255 255
        END
        outlinecolor 0 0 0
        label
        COLOR 0 0 0
#        SHADOWCOLOR 0 218 218
#        SHADOWSIZE 1 1
        TYPE truetype
        encoding GB2312
        font simsun
        MINSIZE 11
        MAXSIZE 256
#       size   8
        POSITION auto
#        PARTIALS FALSE
#        MINDISTANCE 30
        BUFFER 4
        END # end of label
however, when I run
http://localhost/cgi-bin/mapserv?map=/..../....map&layer=xzqj_x&mode=map, it
gives the error:
getString(): Symbol definition error. Parsing error near (name):(line 46).
when I changed labelitem name(Chinese character) to labelitem ename(English)
, everything goes well. I know the problem comes from encoding, but I do not
know how to resolve it , I am confused about the encodings. Any help are
appreciated.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20091021/cca47ace/attachment.htm>


More information about the MapServer-users mailing list