diff options
author | Bernhard Posselt <BernhardPosselt@users.noreply.github.com> | 2016-03-24 14:45:50 +0100 |
---|---|---|
committer | Bernhard Posselt <BernhardPosselt@users.noreply.github.com> | 2016-03-24 14:45:50 +0100 |
commit | 7e9d8b396a87999b7abef7d08c6038af824a70e6 (patch) | |
tree | 506582646d99f0ab9a2ee5c1de40bd8f639e6a25 | |
parent | d3785b5042d5cb8699e1b1748317d7032ad3575d (diff) | |
parent | f1f769a37e37fdcf0549d135e967fe840b10976e (diff) |
Merge pull request #946 from owncloud/multibyte-search
Explicitely use utf-8 encoding
-rw-r--r-- | db/item.php | 3 | ||||
-rw-r--r-- | db/itemmapper.php | 2 |
2 files changed, 3 insertions, 2 deletions
diff --git a/db/item.php b/db/item.php index a5daacc65..153414c93 100644 --- a/db/item.php +++ b/db/item.php @@ -220,7 +220,8 @@ class Item extends Entity implements IAPI, \JsonSerializable { html_entity_decode(strip_tags($this->getBody())) . html_entity_decode($this->getAuthor()) . html_entity_decode($this->getTitle()) . - $this->getUrl() + $this->getUrl(), + 'UTF-8' ) ); $this->setFingerprint($this->computeFingerprint()); diff --git a/db/itemmapper.php b/db/itemmapper.php index b7a594122..895b0f7ae 100644 --- a/db/itemmapper.php +++ b/db/itemmapper.php @@ -68,7 +68,7 @@ class ItemMapper extends NewsMapper { private function buildLikeParameters($search=[]) { return array_map(function ($param) { $param = addcslashes($param, '\\_%'); - return '%' . mb_strtolower($param) . '%'; + return '%' . mb_strtolower($param, 'UTF-8') . '%'; }, $search); } |