netenberg.com
April 23, 2014, 12:29:04 PM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News:
 
   Home   Help Search Login Register  
Pages: [1]   Go Down
  Print  
Author Topic: Funny characters in UPGRADE to WordPress 2.2  (Read 1988 times)
MichaelH
Newbie
*
Posts: 2


« on: May 31, 2007, 01:39:25 PM »

Funny characters are appearing on WordPress blogs that used Fantastico to upgrade to WordPress 2.2.  

If a user upgrades to WordPress 2.2 with Fantastico, the wp-config.php file is being poplulated with the two lines

Code:

define('DB_CHARSET', 'utf8');
define('DB_COLLATE', '');


After the upgrade is completed, those two lines should be deleted to avoid strange characters being displayed on your blog.

It would be interesting if Fantastico developers took note of this problem and incorporated into subsequent releases.

For a new installation of WordPress, it is okay to have those line in wp-config.php.  Again the problem occurs with anyone upgrading from a version prior to 2.2.

http://codex.wordpress.org/Editing_wp-config.php has more explanation about DB_CHARSET and DB_COLLATE.
Logged
Mahendra
Administrator
Maestro
*****
Posts: 1932



« Reply #1 on: June 01, 2007, 05:07:37 AM »

Thanks for the notification.

Questions:-
- What is the default character encoding employed by your MySQL?
- What is the default character collation employed by your MySQL?

I will be looking forward to your answers. It will help us in analyzing the problem.
Logged
MichaelH
Newbie
*
Posts: 2


« Reply #2 on: June 01, 2007, 09:36:20 AM »

Mahendra
Quote

- What is the default character encoding employed by your MySQL?
- What is the default character collation employed by your MySQL?


My host is using cPanel Pro 1.0 (RC36) cPanel build 10.9.0-RELEASE 118

Here's a subset of SHOW variables
character_set_client    utf8
character_set_connection    utf8
character_set_database    latin1
character_set_results    utf8
character_set_server    latin1
character_set_system    utf8
character_sets_dir    /usr/share/mysql/charsets/
collation_connection    utf8_unicode_ci
collation_database    latin1_swedish_ci
collation_server    latin1_swedish_ci

Though, I believe the answer to those questions could vary depending on the user and their host's MySQL setup.    

The problem is, that in the case of an upgrade of WordPress, Fantastico is adding the DB_CHARSET and DB_COLLATE lines to the user's wp-config.php file.  Those lines SHOULD NOT be placed into a user's wp-config.php when upgrading from a version of WordPress (2.1.3 or less) to a 2.2 version of WordPress.  

There are a number of cases on the WordPress Support Forums where user's are complaining about the problem and they are being advised to delete those two lines from their wp-config.php file to solve the problem.

It has also been reported that new installations of WordPress using Fantastico are also experiencing character display problems (see this http://wordpress.org/support/topic/120135 ).  If I install a fresh new copy of WordPress 2.2 using Fantastico, I can not enter a post with the following example (*Characters Č and č (Č and č)*) and have it display on the blog correctly.  If I do a manual install of WordPress version 2.2 (not using Fantastico) I do not experience the problem.  Here's some information that may help you there:

Created by Fantastico installation of WordPress 2.2
Server: localhost - Database: xxxx_wrdp1

   Table    Action    RecordsTip    Type    Collation    Size    Overhead
   wp_categories    Browse    Structure    Search    Insert    Empty    Drop    2    MyISAM    latin1_swedish_ci    3.1 KiB    -
   wp_comments    Browse    Structure    Search    Insert    Empty    Drop    1    MyISAM    latin1_swedish_ci    4.2 KiB    -
   wp_link2cat    Browse    Structure    Search    Insert    Empty    Drop    7    MyISAM    latin1_swedish_ci    3.2 KiB    -
   wp_links    Browse    Structure    Search    Insert    Empty    Drop    7    MyISAM    latin1_swedish_ci    4.6 KiB    -
   wp_options    Browse    Structure    Search    Insert    Empty    Drop    81    MyISAM    latin1_swedish_ci    282.8 KiB    32 B
   wp_post2cat    Browse    Structure    Search    Insert    Empty    Drop    2    MyISAM    latin1_swedish_ci    3.0 KiB    -
   wp_postmeta    Browse    Structure    Search    Insert    Empty    Drop    0    MyISAM    latin1_swedish_ci    5.1 KiB    76 B
   wp_posts    Browse    Structure    Search    Insert    Empty    Drop    3    MyISAM    latin1_swedish_ci    4.8 KiB    -
   wp_usermeta    Browse    Structure    Search    Insert    Empty    Drop    5    MyISAM    latin1_swedish_ci    5.3 KiB    -
   wp_users    Browse    Structure    Search    Insert    Empty    Drop    1    MyISAM    latin1_swedish_ci    3.1 KiB    -


Database created via cPanel MySQL option, installation of WordPress 2.2 done manually
Server: localhost - Database: xxxx_v22

   Table    Action    RecordsTip    Type    Collation    Size    Overhead
   wp_categories    Browse    Structure    Search    Insert    Empty    Drop    2    MyISAM    utf8_general_ci    5.1 KiB    -
   wp_comments    Browse    Structure    Search    Insert    Empty    Drop    1    MyISAM    utf8_general_ci    4.2 KiB    -
   wp_link2cat    Browse    Structure    Search    Insert    Empty    Drop    7    MyISAM    utf8_general_ci    3.2 KiB    -
   wp_links    Browse    Structure    Search    Insert    Empty    Drop    7    MyISAM    utf8_general_ci    4.6 KiB    -
   wp_options    Browse    Structure    Search    Insert    Empty    Drop    78    MyISAM    utf8_general_ci    75.8 KiB    -
   wp_post2cat    Browse    Structure    Search    Insert    Empty    Drop    2    MyISAM    utf8_general_ci    3.0 KiB    -
   wp_postmeta    Browse    Structure    Search    Insert    Empty    Drop    0    MyISAM    utf8_general_ci    7.1 KiB    76 B
   wp_posts    Browse    Structure    Search    Insert    Empty    Drop    3    MyISAM    utf8_general_ci    6.9 KiB    -
   wp_usermeta    Browse    Structure    Search    Insert    Empty    Drop    5    MyISAM    utf8_general_ci    7.3 KiB    -
   wp_users    Browse    Structure    Search    Insert    Empty    Drop    1    MyISAM    utf8_general_ci    3.1 KiB    -
Logged
Mahendra
Administrator
Maestro
*****
Posts: 1932



« Reply #3 on: June 01, 2007, 10:35:06 AM »

Thanks for the answers.

Quote from: "MichaelH"
Though, I believe the answer to those questions could vary depending on the user and their host's MySQL setup.    

The problem is, that in the case of an upgrade of WordPress, Fantastico is adding the DB_CHARSET and DB_COLLATE lines to the user's wp-config.php file.  Those lines SHOULD NOT be placed into a user's wp-config.php when upgrading from a version of WordPress (2.1.3 or less) to a 2.2 version of WordPress.  

There are a number of cases on the WordPress Support Forums where user's are complaining about the problem and they are being advised to delete those two lines from their wp-config.php file to solve the problem.


Yes. I completely understand the problem. Smiley

Quote from: "MichaelH"
If I do a manual install of WordPress version 2.2 (not using Fantastico) I do not experience the problem.  Here's some information that may help you there:


Code:
Fantastico: wp_categories Browse Structure Search Insert Empty Drop 2 MyISAM latin1_swedish_ci 3.1 KiB

Manual: wp_categories Browse Structure Search Insert Empty Drop 2 MyISAM utf8_general_ci 5.1 KiB


The reason for this is what WordPress can forcefully specify utf8 as the character encoding and we cannot (since many of our users still use the 4.0.X branch of MySQL).

We will find an altenate way to handle this situation.

Thanks for your feedback and suggestions.
Logged
Pages: [1]   Go Up
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.15 | SMF © 2011, Simple Machines Valid XHTML 1.0! Valid CSS!