Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > ISPConfig 3 > Developers' Forum

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Thread Tools Display Modes
Old 25th February 2011, 16:56
dar_ek dar_ek is offline
Junior Member
Join Date: Oct 2010
Posts: 17
Thanks: 1
Thanked 3 Times in 2 Posts
Question utf8_decode in modules.inc.php (processDatalog)?

Please tell me for what is utf8_decode() in function processDatalog() from lib/classes/modules.inc.php in that code?

//** encode data to utf-8 and unserialize it
if(!$data = unserialize(stripslashes($d['data']))) {
$data = unserialize($d['data']);
//** Decode data back to locale
foreach($data['old'] as $key => $val) {
$data['old'][$key] = utf8_decode($val);
foreach($data['new'] as $key => $val) {
$data['new'][$key] = utf8_decode($val);

Two times, one for "multiserver setup" and one for "single server setup".

I'm asking this because "utf8_decode" here damages all locale character set.
Eg. in autoresponder text. Also in "multiserver setup" section this breaking all locale characters (UTF-8) in replication from master database.

(In my case POLISH characterset).
Reply With Quote
Sponsored Links
Old 25th February 2011, 18:43
till till is online now
Super Moderator
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 37,014
Thanks: 840
Thanked 5,651 Times in 4,461 Posts

I've just reviewed the code again, it might indeed be that the lines can be removed now, we had some code there that encoded everything to utf-8 to solve serialization problems, but that code has been removed, so that the decode part might be removed as well.
Till Brehm
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
The Following User Says Thank You to till For This Useful Post:
dar_ek (25th February 2011)
Old 25th February 2011, 21:47
dar_ek dar_ek is offline
Junior Member
Join Date: Oct 2010
Posts: 17
Thanks: 1
Thanked 3 Times in 2 Posts

Thanks for quick answer.

I'll test it, and sing you in case of problems.

Best regards/
Reply With Quote


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

All times are GMT +2. The time now is 19:32.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.