FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » FUDforum » FUDforum Installation Issues » charset problems
Show: Today's Messages :: Polls :: Message Navigator
Switch to threaded view of this topic Create a new topic Submit Reply
charset problems [message #164192] Sat, 08 January 2011 13:19 Go to next message
valpis is currently offline  valpis
Messages: 7
Registered: July 2008
Karma: 0
Junior Member
I am in the process of moving the forum from an FreeBSD to Linux server and during the time also upgrade from 2.7.6 to 3.0.2.

The only thing I can't figure out is how to get the swedish characters corrctly displayed.

The messages is stored in files, running file on one message file gets me:
msg_50000: ISO-8859 text, with very long lines, with CRLF line terminators

The database is in UTF-8, I have changed the charset in the template to UTF-8. I have rebuild the theme, I have runned compress messages, but still gets garbage on the text read from files (from db everything is ok).
I treied to run iconv on the files, but that of course changed the offsets on the messages in the file Smile

/johan
Re: charset problems [message #164193 is a reply to message #164192] Sat, 08 January 2011 13:35 Go to previous messageGo to next message
valpis is currently offline  valpis
Messages: 7
Registered: July 2008
Karma: 0
Junior Member
and after some more reading there seems lika I should have an extra option when chosing compress messages for changing charset, this one I doesn't get, but I have this enabled in php



iconv support => enabled
iconv implementation => glibc
iconv library version => 2.5
iconv.input_encoding => ISO-8859-1 => ISO-8859-1
iconv.internal_encoding => ISO-8859-1 => ISO-8859-1
iconv.output_encoding => ISO-8859-1 => ISO-8859-1
Re: charset problems [message #164194 is a reply to message #164193] Sat, 08 January 2011 13:42 Go to previous messageGo to next message
naudefj is currently offline  naudefj   South Africa
Messages: 3771
Registered: December 2004
Karma: 28
Senior Member
Administrator
Core Developer
See Compact Messages:
"If your PHP installation doesn't have the iconv module enabled, you will not see the character set conversion options."
Re: charset problems [message #164195 is a reply to message #164194] Sat, 08 January 2011 13:43 Go to previous messageGo to next message
valpis is currently offline  valpis
Messages: 7
Registered: July 2008
Karma: 0
Junior Member
yes, but according to both commandline php and phpinfo() I do have that enabled
Re: charset problems [message #164197 is a reply to message #164195] Sat, 08 January 2011 13:46 Go to previous messageGo to next message
naudefj is currently offline  naudefj   South Africa
Messages: 3771
Registered: December 2004
Karma: 28
Senior Member
Administrator
Core Developer
Check compact.php:
<?php if (@extension_loaded('iconv')) {...
Re: charset problems [message #164198 is a reply to message #164197] Sat, 08 January 2011 13:53 Go to previous messageGo to next message
valpis is currently offline  valpis
Messages: 7
Registered: July 2008
Karma: 0
Junior Member
created this:
<?php if (@extension_loaded('iconv')) {
        print('installed');
}else {
        print('not installed');
}
?>




and the output gave me "installed"

but the I added some debug output in compact.php, and that condition never returned true

[Updated on: Sat, 08 January 2011 14:03]

Report message to a moderator

Re: charset problems [message #164200 is a reply to message #164198] Sat, 08 January 2011 16:22 Go to previous messageGo to next message
valpis is currently offline  valpis
Messages: 7
Registered: July 2008
Karma: 0
Junior Member
I did a clean installation of 3.0.2 now instead of the upgrading path, but the same result.

For what it is worth, my system info (Centos 5.3):

FUDforum version: 3.0.2
PHP version: 5.1.6
PHP built on: Linux 2.6.18-028stab069.6-ent #1 SMP Wed May 26 18:25:22 MSD 2010 i686
Database type: mysql (mysql)
Database version: 5.0.77
Web server: Apache/2.2.3 (CentOS)
Web Server load: 0
Web server to PHP interface: apache2handler
WebServer User/Group: 48 / 48
Relevant PHP settings:
Safe mode: OFF
Open basedir: none
Display errors: OFF
File uploads: ON
Maximum file upload size: 2M
Magic quotes: OFF
Register globals: OFF
Output buffering: Yes
Disabled functions: none
PSpell support: Yes
Zlib support: Yes
Re: charset problems [message #164201 is a reply to message #164200] Sat, 08 January 2011 16:56 Go to previous messageGo to next message
naudefj is currently offline  naudefj   South Africa
Messages: 3771
Registered: December 2004
Karma: 28
Senior Member
Administrator
Core Developer
This is not a FUDforum problem.
Maybe add more debugging statements to see why iconv isn't loaded.
Re: charset problems [message #164202 is a reply to message #164201] Sat, 08 January 2011 17:21 Go to previous message
valpis is currently offline  valpis
Messages: 7
Registered: July 2008
Karma: 0
Junior Member
well, actually it was a problem in FUD, in compact.php the code looked like this
<!-- REMOVE
<?php if (@extension_loaded('iconv')) {


and by removing the line with REMOVE (and the corresponding end comment) it actually worked
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Help with warnings during upgrade to 3.0.0
Next Topic: Serious upgrade problem: SQL syntax error
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Fri May 24 14:22:42 GMT 2024

Total time taken to generate the page: 0.03847 seconds