About unicode ant other non-latin1 charsets

If you would like to check the status of a language, volunteer to do a translation, or highlight or correct a problem in one of the existing language files then post here.
Post Reply
Posts: 4
Joined: Thu Nov 20, 2008 12:07 pm

About unicode ant other non-latin1 charsets

Post by miwa » Thu Nov 20, 2008 12:53 pm

There are many messages on this forum, where people have different troubles with encodings. This is becouse in ZoneMinder's code is using php function htmlentities which converts it's param into latin1, if other not set manually.

I solved this problem by replacing all lines, which includes this function, from htmlentities($some_text) to htmlentities($some_text, ENT_COMPAT, "UTF-8").

Would be better to make some patch for this, but it must to include also support for other, non-utf charsets, so i don't know, how to do it quickly and correctly :(

Posts: 21
Joined: Wed Oct 21, 2009 6:45 pm

Re: About unicode ant other non-latin1 charsets

Post by marcodefreitas » Wed Feb 01, 2012 9:05 am

The definitive solution is to port Zoneminder to UTF-8, as the most of sites and GNU/Linux distros already done.
Start using gettext is good too.

Posts: 1
Joined: Mon Mar 13, 2006 1:34 pm

Re: About unicode ant other non-latin1 charsets

Post by lokidor » Wed Jun 05, 2013 8:48 am

For proper display of unicode characters on a server with utf-8 enabled in php, the php language files (in the lang folder) have to be encoded in utf-8.
I noticed it was not the case for my native language (french).
I fixed the issue by editing the file with vim and convert it to utf-8 with the following command in vim:

Code: Select all

:set fileencoding=utf-8
Not necessary, but I also forced utf-8 rendering in the web browser by decommenting the header line in the file and changing it to:

Code: Select all

header( "Content-Type: text/html; charset=utf-8" );
I hope this can help someone.

Posts: 1
Joined: Sun Oct 12, 2014 8:27 am

Re: About unicode ant other non-latin1 charsets

Post by linflaas » Sun Oct 12, 2014 8:32 am

Hi all,

Having accentuated french characters not well displayed, i've just tried this :

sudo cp -p fr_fr.php fr_fr.php_sav
sudo iconv -f ISO-8859-15 -t UTF-8 -o fr_fr.php_utf8 fr_fr.php
sudo cp -p fr_fr.php_utf8 fr_fr.php

In the lang directory : /usr/share/zoneminder/lang

Then it seems to work well

Have nice day all

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest