[mapserver-users] Encoding problem

thomas bonfort thomas.bonfort at gmail.com
Mon Oct 26 12:11:02 PDT 2015


> RFC suggests all characters should iconv'd to
> UTF-8. Am I right?
If you're creating the datasource from scratch and have the choice,
then yes, use UTF8. If you have an exisiting datasource you cannot
modify, just set the LAYER->ENCODING to ISO-8859 (well, the one that
is is supported by iconv) and the transormation to utf8 will be done
automatically and internally by mapserver.

--
thomas

>
>
> -Stefanos
>
>
>
>
> Στις 8:25 μ.μ. Δευτέρα, 26 Οκτωβρίου 2015, ο/η thomas bonfort
> <thomas.bonfort at gmail.com> έγραψε:
>
>
> Stefanos,
> First off, you *need* to know the encoding that's actually used by
> each datasource, there's no way of guessing that reliably
> programmatically. And since MapServer 7, the ENCODING keyword has been
> moved to the LAYER level:
> http://mapserver.org/development/rfc/ms-rfc-103.html
> If you have the possibility, and/or in the future, always use UTF8
> inside your datasources.
>
> regards,
> thomas
>
> On 26 October 2015 at 19:16, Stefanos Anastasiou <emperor_stef at yahoo.gr>
> wrote:
>> Hello everybody.
>>
>> I'm having a small issue with truetype and encoding in greek. Instead of
>> normal letters I'm getting weird symbols or even shapes.
>>
>> iconv -l | grep {GREEK |  ISO-8859-7 | WINDOWS-1253}          are all
>> present in the system.
>>
>>
>> My Mapserver version:
>>
>> MapServer version 7.0.0 OUTPUT=PNG OUTPUT=JPEG OUTPUT=KML SUPPORTS=PROJ
>> SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=CAIRO SUPPORTS=ICONV SUPPORTS=XMP
>> SUPPORTS=FRIBIDI SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT
>> SUPPORTS=WFS_SERVER
>> SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER
>> SUPPORTS=FASTCGI
>> SUPPORTS=GEOS INPUT=JPEG INPUT=POSTGIS INPUT=OGR INPUT=GDAL
>> INPUT=SHAPEFILE
>>
>>
>> My LABEL object in my code is the following:
>>
>>            LABEL
>>                TYPE truetype
>>                FONT arial
>>                SIZE 6
>>                PARTIALS TRUE
>>                ENCODING GREEK
>>            END
>>
>> I also tried ENCODING ISO-8859-7 and WINDOWS-1253. But getting symbols
>> instead of letters. The closest to human readable is with encoding
>> UTF-8...
>> but still.
>>
>> I'm probably missing something here.What is the problem ?
>
>>
>>
>>
>>
>>
>>
>> _______________________________________________
>> mapserver-users mailing list
>> mapserver-users at lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
>


More information about the mapserver-users mailing list