Open ghost opened 12 years ago
I suspect this is an issue with char set. If you open inc/header.php on line 35 it says;
try changing that to the following; ""
I believe that is the most relevant issue with regards to character set. There are a couple other occurrences, with relation to script includes. Without some Cryillic data to test on I can't tell if that works. (If you can confirm it, I will push the change)
I changed:
/echelon/inc/header.php from 36 meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" to 36 meta http-equiv="Content-Type" content="text/html; charset=utf-8"
/echelon/lib/plugins/chatlogs/class.php from 310 $msg = cleanvar(removeColorCode($data['msg'])); to 310 $msg = removeColorCode($data['msg']);
After that, everything was displayed correctly http://s59.radikal.ru/i164/1111/96/535bd18898e5.jpg
I assume it fails without the removal of cleanvar in echelon/lib/plugins/chatlogs/class.php?
The cleanvar is there as anti-injection, and it's removal is not safe, but from looking at the documentation on some of the functions used in there (htmlentities specifically) it appears that that function also needs a charset. I will try and add an option to switch between multiple character sets so that the code will do the conversion for you, because you do want cleanvar() in there.
Here's how it was in the original: $msg = cleanvar(removeColorCode($data['msg'])); http://s017.radikal.ru/i433/1111/eb/0c3c22dbfa9b.jpg
after changing: $msg = removeColorCode($data['msg']); http://s017.radikal.ru/i432/1111/96/b788e715ca62.jpg
all as set above. does not work http://s45.radikal.ru/i109/1210/53/d5f1eebbd6e8.png http://s47.radikal.ru/i116/1210/97/1a43ba804ed0.png
Debian
all as set above. does not work http://s45.radikal.ru/i109/1210/53/d5f1eebbd6e8.png http://s47.radikal.ru/i116/1210/97/1a43ba804ed0.png
Debian
@Leden4ik Замени в файле echelon/lib/plugins/chatlogs/class.php $msg = cleanvar(removeColorCode($data['msg'])); на $msg = removeColorCode($data['msg']);
и в файле echelon/inc/header.php meta http-equiv="Content-Type" content="text/html; charset="<?php echo $charset;?>" / на meta http-equiv="Content-Type" content="text/html; charset=utf-8" / (знаки больше-меньше убрал, т.к. не правильно отображались)
После этого всё должно работать.
ПС: аналогично, убрав cleanvar, можно поступить и здесь - http://www.banbutton.com/index.php/alternative-chatlog-page-for-echelon/
В общем проблема с кирилицой все равно атуальна, все прописано как есть, но вместо русского вечно вопросительные знаки
И да проблема не со стороны чата, а вообщем по всему сайту меняя названия на русское значения, то где бы то не было отображение идет вопросами
Ну у меня ж работает http://s017.radikal.ru/i440/1302/b2/c824db568996.jpg
Нет вы не поняли, так у меня по всему сайту, к примеру отредактировав в базе группы, и обозначив их русскими символами, все равно идет выдача вопросиков и именно только с echelon, так как отображение других сайтов на данной тачке нормальное.
Хочу спросить вас, у вас база в какой кодировке?
Ибо не понятно, почему такой вывод =(
В основном кодировка - utf8_general_ci Название групп эшелона, если переименовать, у меня отображаются корректно. Или о каких группах речь?
Подскажите пожалуйста!!! Почему у меня такие закорячки в базе данных óõ òû ëèâåíü в базе данных кодировка utf8 Сайт отображается без проблем по умолчанию кодировка utf8, а всё равно óõ òû ëèâåíü такие вот закорячки в логах чата , база данных Mysql помоги пожалуйста ?
In chatlog not display Cyrillic characters: http://s017.radikal.ru/i400/1111/3e/d80da7ba4875.jpg http://s017.radikal.ru/i424/1111/03/dbef149370b6.jpg http://i027.radikal.ru/1111/47/3a885d600895.jpg