national signs

Fixed and closed topics
Locked
unsec
User
Posts: 36
Joined: Sat May 02, 2009 10:56 am

national signs

Post by unsec »

initialize.inc.php

Code: Select all

if (NJB_WINDOWS)	define('NJB_DEFAULT_CHARSET', ($cfg['default_charset'] == '') ? 'ISO-8859-1' : $cfg['default_charset']);
else				define('NJB_DEFAULT_CHARSET', ($cfg['default_charset'] == '') ? 'UTF-8' : $cfg['default_charset']);
I have problem with Polish national signs -> ąęśćżźółń

when I change ISO-8859-1 to 8859-2 -> NJB call UTF-8

so when I change ISO-8859-1 to UTF-8

artist - Alizée
in NJB 6 - blank place, no link

Polish national signs - wrong too

brgs
Last edited by unsec on Thu Sep 19, 2013 11:54 pm, edited 1 time in total.
User avatar
wbartels
netjukebox developer
Posts: 872
Joined: Thu Nov 04, 2004 3:12 pm
Location: Netherlands
Contact:

Re: national signs

Post by wbartels »

This is not a netjukebox bug!

PHP 5.x can't read multibyte filesystem characters from a Windows operating system.
But can from Linux, Unix and OS-X:

https://live.netjukebox.nl/index.php?ac ... uehgiui3f9
Attachments
UTF-8 example files
UTF-8 example files
CapturFiles.png (44.49 KiB) Viewed 25714 times
unsec
User
Posts: 36
Joined: Sat May 02, 2009 10:56 am

Re: national signs

Post by unsec »

Now I know, You have right and you have not. Why? Couse we (you and me) have WRONG version of our PHP (not unicode version of PHP). I'm using last version of WAMP serwer and I will write to author to recompile this serwer.

so, here is article about this problems like ours. Generally, PHP MUST correct working in every place, Windows, Unix, Mac.

http://evertpot.com/filesystem-encoding-and-php/

Ps. probably here is better explanation of the right way (recompile PHP with UNICODE version of Win32 API) - http://stackoverflow.com/questions/9659 ... on-windows
User avatar
wbartels
netjukebox developer
Posts: 872
Joined: Thu Nov 04, 2004 3:12 pm
Location: Netherlands
Contact:

Re: national signs

Post by wbartels »

If you have a working Windows PHP unicode version than set the default charset to UTF-8 in the config.inc.php file.

Code: Select all

//  +------------------------------------------------------------------------+
//  | Default characterset                                                   |
//  +------------------------------------------------------------------------+
//  | When leaving empty it will use the ISO-8859-1 characterset for Windows |
//  | and UTF-8 for all other operating systems.                             |
//  +------------------------------------------------------------------------+
$cfg['default_charset']             = 'UTF-8';
unsec
User
Posts: 36
Joined: Sat May 02, 2009 10:56 am

Re: national signs

Post by unsec »

maybe my problem will gone couse my target is locate netjukebox on Synology serwer. Or new problems will come :)))
Locked