Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I am trying to create posts in hindi language. These characters UÉeÉMÑüqÉÉU after saving/publishing are interpreted as U�e�M��q��U. Though, the special characters are stored with no change in the mysql database. The symbol is only during retrieving. I'm stuck here. The post editor is modified to intake multiple posts. http://www.farinspace.com/multiple-wordpress-wysiwyg-visual-editors/

I tried commenting these lines in wp-config.php. But none worked.

/** Database Charset to use in creating database tables. */
define('DB_CHARSET', 'UTF-8');

/** The Database Collate type. Don't change this if in doubt. */
define('DB_COLLATE', '');

Also, placed mysql_query("SET NAMES utf8"); in wpdb class constructor of wp-db.php. Negative, even this didn't work

How do i overcome this?

share|improve this question
    
Don't edit any core files –  Sisir Jul 22 '12 at 17:00

2 Answers 2

try

define('DB_CHARSET', 'utf8');

this is what's in my wp-config.php

and remove

define('DB_CHARSET', 'UTF-8');

share|improve this answer
    
Reference link to WordPress Codex –  its_me Jul 22 '12 at 16:38
    
Ain't DB_COLLATE the one that would deal with this issue? –  brasofilo Jul 22 '12 at 17:24
    
@Damien that didn't work!!! I still find �� –  nuthan Jul 22 '12 at 17:58
    
@nuthan I would suspect that existing data in your SQL database is not UTF-8. Have you tried adding new content in Hindi? Also this article might help you srinix.wordpress.com/2007/08/29/… –  Damien Jul 22 '12 at 20:47
    
@Damien the content is stored in wp_postmeta table, meta_value field, collation:utf8_general_ci. I am coping the hindi content from MS-word document. Does this affect in copying the format? I usually copy it to notepad b4 pasting it to the wordpress editor, To avoid MS-word styles. –  nuthan Jul 22 '12 at 21:38
up vote 1 down vote accepted

Its utf-8 character encoding problem. Fixed it using the function utf8_encode():

utf8_encode(html_entity_decode($mb->get_the_value()));
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.