After upgrading from 1.5.4.1 to 1.5.5.1 I am getting the following error:
PHP Warning: htmlspecialchars(): Invalid multibyte sequence in argument in httpdocs/system/library/request.php on line 33
Line 33 of request.php is inside the following function:
public function clean($data) {
if (is_array($data)) {
foreach ($data as $key => $value) {
unset($data[$key]);
$data[$this->clean($key)] = $this->clean($value);
}
} else {
$data = htmlspecialchars($data, ENT_COMPAT, 'UTF-8'); <!-- THIS IS LINE 33 -->
}
return $data;
}
Any idea?
same for me....
in the url there are some encoded symbols like the german ÖÄÜ etc. They are urlencoded to something like %F6 (thats the german "ö".
I think this is causing the error. But I don't know how to solve it...
in the url there are some encoded symbols like the german ÖÄÜ etc. They are urlencoded to something like %F6 (thats the german "ö".
I think this is causing the error. But I don't know how to solve it...
DG-Webservices- Webdesign und Programmierung aus Friesland
I found the reason...
in the former request.php there was the following line:
now there is the following:
Thats why non-UTF8 urls can not be parsed anymore. I think it is a bug ...
in the former request.php there was the following line:
Code: Select all
$data = htmlspecialchars($data, ENT_COMPAT);
Code: Select all
$data = htmlspecialchars($data, ENT_COMPAT, 'UTF-8');
DG-Webservices- Webdesign und Programmierung aus Friesland
I found two websites that might provide some info, but does not solve problem. They seem to say the problem is with the string being passed as an argument to htmlspecialchars(). In that case, where does that string come from?
http://scito.ch/content/php-multibyte-u ... lem-solved
http://insomanic.me.uk/post/191397106/p ... es-invalid
http://scito.ch/content/php-multibyte-u ... lem-solved
http://insomanic.me.uk/post/191397106/p ... es-invalid
(1) On changing the line back and removing the UTF-8 parameter, probably not but try it both ways.
(2) Try opening the file(s) and resaving as UTF-8 WITHOUT BOM. That has salvaged language packs, it might work with this. The problem arises when an ascii editor saves with a flavor; BOM. Properly pure ascii editors don't do that. If there is a specific setting for saving with carriage returns and linefeeds for Windows or for Linux, be certain not to save the wrong way for files uploaded to the server.
(2) Try opening the file(s) and resaving as UTF-8 WITHOUT BOM. That has salvaged language packs, it might work with this. The problem arises when an ascii editor saves with a flavor; BOM. Properly pure ascii editors don't do that. If there is a specific setting for saving with carriage returns and linefeeds for Windows or for Linux, be certain not to save the wrong way for files uploaded to the server.
Hello,
Google is wonderfull.
Read this
https://www.93i.de/devzone/opencart-htm ... e-sequence
I hope this solves the problem.
Henk
Google is wonderfull.
Read this
https://www.93i.de/devzone/opencart-htm ... e-sequence
I hope this solves the problem.
Henk
Who is online
Users browsing this forum: No registered users and 3 guests