Hello.
There is a display problem in Japanese, shown by JavaScript function show_popup_menu.
OnClick() display strings passed are processed at CTag::AddAction() in file ctag.inc.php.
PHP function htmlentities() has default charset ISO-8859-1.
By adding charset locale constant S_HTML_CHARSET to htmlentities(), the problem resolved.
It should work both cn and ru.
Below is the small patch.
Sincerely.
There is a display problem in Japanese, shown by JavaScript function show_popup_menu.
OnClick() display strings passed are processed at CTag::AddAction() in file ctag.inc.php.
PHP function htmlentities() has default charset ISO-8859-1.
By adding charset locale constant S_HTML_CHARSET to htmlentities(), the problem resolved.
It should work both cn and ru.
Below is the small patch.
Sincerely.
Code:
# diff -u php/include/classes/ctag.inc.php.orig php/include/classes/ctag.inc.php
--- php/include/classes/ctag.inc.php.orig 2007-10-05 23:38:54.000000000 +0900
+++ php/include/classes/ctag.inc.php 2007-10-09 16:11:36.000000000 +0900
@@ -254,7 +254,7 @@
function AddAction($name, $value)
{
if(!empty($value))
- $this->options[$name] = htmlentities(str_replace(array("\r", "\n"), '', strval($value)),ENT_COMPAT);
+ $this->options[$name] = htmlentities(str_replace(array("\r", "\n"), '', strval($value)),ENT_COMPAT,S_HTML_CHARSET);
}
function AddOption($name, $value)
Comment