Oh no! Where's the JavaScript?
Your Web browser does not have JavaScript enabled or does not support JavaScript. Please enable JavaScript on your Web browser to properly view this Web site, or upgrade to a Web browser that does support JavaScript.
Not a member yet? Click here to register.
Forgot Password?

UTF-8

Asked Modified Viewed 13,709 times
K
KFJ
K
KFJ 10
With a paid licens.....
  • Member, joined since
  • Contributed 55 posts on the community forums.
  • Started 10 threads in the forums
  • Started this discussions
asked
Member

Hi there,

Wasn't sure where I should post this, so it's posted here.

In ver. 6 it was possible at my site to write posts in the forum in both english, danish and thai, but after the update to ver. 7 it's only possible to write english and danish. When trying to post something which contain thai it change to something unreadable as following:

Quote

ตุลาคม ทำบุญออกพรรษา / ตักบาตรเทโวโรห

Is there any way to add thai too in ver. 7, so it again will be possible for my users to mix between the languages ?

I'm not sure if the problem is in the database where I using UTF-8 Unicode or in the way PHPFusion handle thai when posting something.

Hope someone can help me.
Thanks :-)

BTW: I just try here at this site too. It's not possible to use thai here too.
0 replies

19 posts

K
KFJ
K
KFJ 10
With a paid licens.....
  • Member, joined since
  • Contributed 55 posts on the community forums.
  • Started 10 threads in the forums
  • Started this discussions
answered
Member

Anyone please ?
0 replies
— 3 months later —
K
KFJ
K
KFJ 10
With a paid licens.....
  • Member, joined since
  • Contributed 55 posts on the community forums.
  • Started 10 threads in the forums
  • Started this discussions
answered
Member

I try with a BUMP again.
0 replies
H
hame
H
hame 10
  • Senior Member, joined since
  • Contributed 423 posts on the community forums.
  • Started 44 threads in the forums
answered
Senior Member

you have to change the CharSet, or get a Thai locale for your site.
win-874
tis-620
0 replies
F
Falk
F
Falk 131
Need help?, Having trouble?
• View our Documentation for Guides, Standards and Functions
• Name and Organize your Topics and Content correctly in the corresponding Forums for best support results
• Attaching Log Files and Screenshots when reporting issues will help
• Provide with an URL to live example if one exists
• Please read the How to Report an Error post
• Please read and comply with the Code of Conduct

(¯·._.·(¯°·._.·°º*[ Project Manager ]*º°·._.·°¯)·._.·¯)
  • Super Admin, joined since
  • Contributed 6,201 posts on the community forums.
  • Started 639 threads in the forums
  • Answered 11 questions
answered
Super Admin

Just a stab in the dark but try replacing the stripinput function in maincore.php (lines 313-320) with:

// Strip Input Function, prevents HTML in unwanted places
function stripinput($text) {
   if (QUOTES_GPC) $text = stripslashes($text);
   $search = array("\"", "'", "\\", '\"', "\'", "<", ">", "&nbsp;");
   $replace = array("&quot;", "&#39;", "&#92;", "&quot;", "&#39;", "&lt;", "&gt;", " ");
   $text = str_replace($search, $replace, $text);
   return $text;
}
0 replies
K
KFJ
K
KFJ 10
With a paid licens.....
  • Member, joined since
  • Contributed 55 posts on the community forums.
  • Started 10 threads in the forums
  • Started this discussions
answered
Member

Quote

Digitanium wrote:
Just a stab in the dark but try replacing the stripinput function in maincore.php (lines 313-320) with:

// Strip Input Function, prevents HTML in unwanted places
function stripinput($text) {
   if (QUOTES_GPC) $text = stripslashes($text);
   $search = array("\"", "'", "\\", '\"', "\'", "<", ">", "&nbsp;");
   $replace = array("&quot;", "&#39;", "&#92;", "&quot;", "&#39;", "&lt;", "&gt;", " ");
   $text = str_replace($search, $replace, $text);
   return $text;
}

Thanks Digi :-)

It seems like this solution helps. Now, it's both possible to write english, thai and danish with the speciel letters (æøåÆØÅ) again.

Thanks for your help :-)
0 replies
A
archeens
A
  • Junior Member, joined since
  • Contributed 28 posts on the community forums.
  • Started 1 thread in the forums
answered
Junior Member

for me it didnt helped

http://testswc3.wc3.lv
0 replies
K
KFJ
K
KFJ 10
With a paid licens.....
  • Member, joined since
  • Contributed 55 posts on the community forums.
  • Started 10 threads in the forums
  • Started this discussions
answered
Member

Quote

archeens wrote:
for me it didnt helped

http://testswc3.wc3.lv

Sad to hear, but maybe we not had the same problem. At my site it was possible to read the old post written in thai in v6, just not possible to write new posts in thai with v7 before this solution from Digi.
0 replies
— 2 years later —
E
emilife93
E
  • Member, joined since
  • Contributed 176 posts on the community forums.
  • Started 49 threads in the forums
answered
Member

it working for me in v7.01.04

but when i upgrade to v7.01.05 and i put same code

// Strip Input Function, prevents HTML in unwanted places
function stripinput($text) {
   if (QUOTES_GPC) $text = stripslashes($text);
   $search = array("\"", "'", "\\", '\"', "\'", "<", ">", "&nbsp;");
   $replace = array("&quot;", "'", "\", "&quot;", "'", "&lt;", "&gt;", " ");
   $text = str_replace($search, $replace, $text);
   return $text;
}
[/quote]

not working..

anyone can help?
Edited by emilife93 on 24-02-2011 19:03,
0 replies
E
emilife93
E
  • Member, joined since
  • Contributed 176 posts on the community forums.
  • Started 49 threads in the forums
answered
Member

this thread dont have anymore support?....
0 replies
C
Craig
C
Craig 14
  • Fusioneer, joined since
  • Contributed 4,462 posts on the community forums.
  • Started 212 threads in the forums
answered
Fusioneer

Emilife93, please be patient a experienced user will help you at some point.

Please also remember the Rules regarding Double Posting.
0 replies
E
emilife93
E
  • Member, joined since
  • Contributed 176 posts on the community forums.
  • Started 49 threads in the forums
answered
Member

Quote

Fangree_Craig wrote:
Emilife93, please be patient a experienced user will help you at some point.

Please also remember the Rules regarding Double Posting.


ok....sory for mistake
0 replies
A
Ankur
A
Ankur 10
Hi! Its me, Ankur Thakur! smile
  • Veteran Member, joined since
  • Contributed 1,277 posts on the community forums.
  • Started 60 threads in the forums
answered
Veteran Member

@EmiLife : Try changing these values in locale/Your_Locale/global.php :

$locale['charset'];
$locale['xml_lang'];
$locale['tinymce'];
$locale['phpmailer'];

Set the Charset to UTF-8 and the xml lang to your Language Code !
0 replies
E
emilife93
E
  • Member, joined since
  • Contributed 176 posts on the community forums.
  • Started 49 threads in the forums
answered
Member

but when i use http://validator.w3.org to validate check i get this error after change the Character Encoding

1. Error

Sorry, I am unable to validate this document because on line 370 it contained one or more bytes that I cannot interpret as utf-8 (in other words, the bytes found are not valid values in the specified Character Encoding). Please check both the content of the file and the character encoding indication.

The error was: utf8 "\x93" does not map to Unicode
Edited by emilife93 on 25-02-2011 16:51,
0 replies
J
jantom
J
jantom 10
...because the Prophet is only one...
  • Junior Member, joined since
  • Contributed 44 posts on the community forums.
  • Started 6 threads in the forums
answered
Junior Member

Did you convert database to utf-8 before you changed global.php? Without this operation, Ankur's idea can't work.
0 replies
E
emilife93
E
  • Member, joined since
  • Contributed 176 posts on the community forums.
  • Started 49 threads in the forums
answered
Member

Quote

jantom wrote:
Did you convert database to utf-8 before you changed global.php? Without this operation, Ankur's idea can't work.


how to convect that ?
0 replies
A
Ankur
A
Ankur 10
Hi! Its me, Ankur Thakur! smile
  • Veteran Member, joined since
  • Contributed 1,277 posts on the community forums.
  • Started 60 threads in the forums
answered
Veteran Member

Quote

jantom wrote:
Did you convert database to utf-8 before you changed global.php? Without this operation, Ankur's idea can't work.


But I am using Hindi Language with UTF-8 just by this method without changing the Database Character set, i.e Collation ! And My website is Validated except those HTML errors like on using onmouseout and onmousehover functions !
0 replies
E
emilife93
E
  • Member, joined since
  • Contributed 176 posts on the community forums.
  • Started 49 threads in the forums
answered
Member

Ankur i Set the Charset to UTF-8 and the xml lang to Arabic Language Code ! and it working

but when i want to validator i get this error

Sorry, I am unable to validate this document because on line 480 it contained one or more bytes that I cannot interpret as utf-8 (in other words, the bytes found are not valid values in the specified Character Encoding). Please check both the content of the file and the character encoding indication.

The error was: utf8 "\x93" does not map to Unicode
0 replies
A
Ankur
A
Ankur 10
Hi! Its me, Ankur Thakur! smile
  • Veteran Member, joined since
  • Contributed 1,277 posts on the community forums.
  • Started 60 threads in the forums
answered
Veteran Member

For better response, you should Post on Arabic Site : http://www.phpfusion-ar.com/news.php
0 replies
B
behrooz
B
  • Member, joined since
  • Contributed 122 posts on the community forums.
  • Started 29 threads in the forums
answered
Member

hi , my site is persian .

please test :

$config['charset'] = "utf-8";

if not work test on this:

$locale['charset'] = "utf-8";
0 replies

Category Forum

Installation Issues - 8

Labels

None yet

Statistics

  • Views 0 views
  • Posts 19 posts
  • Votes 0 votes
  • Topic users 9 members

9 participants

F
F
Falk 131
Need help?, Having trouble?
• View our Documentation for Guides, Standards and Functions
• Name and Organize your Topics and Content correctly in the corresponding Forums for best support results
• Attaching Log Files and Screenshots when reporting issues will help
• Provide with an URL to live example if one exists
• Please read the How to Report an Error post
• Please read and comply with the Code of Conduct

(¯·._.·(¯°·._.·°º*[ Project Manager ]*º°·._.·°¯)·._.·¯)
  • Super Admin, joined since
  • Contributed 6,201 posts on the community forums.
  • Started 639 threads in the forums
  • Answered 11 questions
K
K
KFJ 10
With a paid licens.....
  • Member, joined since
  • Contributed 55 posts on the community forums.
  • Started 10 threads in the forums
  • Started this discussions
C
C
Craig 14
  • Fusioneer, joined since
  • Contributed 4,462 posts on the community forums.
  • Started 212 threads in the forums
J
J
jantom 10
...because the Prophet is only one...
  • Junior Member, joined since
  • Contributed 44 posts on the community forums.
  • Started 6 threads in the forums
H
H
hame 10
  • Senior Member, joined since
  • Contributed 423 posts on the community forums.
  • Started 44 threads in the forums
A
A
  • Junior Member, joined since
  • Contributed 28 posts on the community forums.
  • Started 1 thread in the forums
B
B
  • Member, joined since
  • Contributed 122 posts on the community forums.
  • Started 29 threads in the forums
E
E
  • Member, joined since
  • Contributed 176 posts on the community forums.
  • Started 49 threads in the forums
A
A
Ankur 10
Hi! Its me, Ankur Thakur! smile
  • Veteran Member, joined since
  • Contributed 1,277 posts on the community forums.
  • Started 60 threads in the forums

Notifications

Track thread

You are not receiving notifications from this thread.

Related Questions

Not yet