Commit Graph

13 Commits

Author SHA1 Message Date
Maurício Meneghini Fauth
e330402b5b Refactor the core functions into static methods
Signed-off-by: Maurício Meneghini Fauth <mauriciofauth@gmail.com>
2017-06-03 00:52:22 -03:00
Michal Čihař
7cea5eb9af Replace our mbstring polyfills with symfony/polyfill-mbstring
The symfony/polyfill-mbstring is anyway pulled in through Twig, so this
doesn't add additional dependencies.

Fixes #12386

Signed-off-by: Michal Čihař <michal@cihar.com>
2017-05-17 10:03:30 +02:00
Michal Čihař
ae9006e9be Use one temporary directory
Share one directory for Twig cache, SHP import and file uploads.

The code now also validates the cache directory and creates it on the
fly, so it properly detects if the directory can not be used.

Also the documentation has been improved to document securing this
directory.

Fixes #13225
Fixes #13226

Signed-off-by: Michal Čihař <michal@cihar.com>
2017-05-05 11:08:36 +02:00
Maurício Meneghini Fauth
750e42916f Fix some coding standard errors
Signed-off-by: Maurício Meneghini Fauth <mauriciofauth@gmail.com>
2017-03-23 11:08:30 -03:00
osaid
b8a9b0f30d Share code for getting temporary directory
Changed Encoding.php and File.php.

Fixes #12514

Signed-off-by: Osaid <osaid.nasir@gmail.com>
Signed-off-by: Michal Čihař <michal@cihar.com>
2016-11-28 12:12:59 +01:00
Madhura Jayaratne
52b75f4b16 Remove line breaks
Signed-off-by: Madhura Jayaratne <madhura.cj@gmail.com>
2016-03-10 20:23:37 +11:00
Michal Čihař
1a9df888a7 Remove Kanji encoding detection
Since we set utf-8 as internal charset, there is no need to detect it.

Signed-off-by: Michal Čihař <michal@cihar.com>
2016-03-08 15:46:37 +01:00
Michal Čihař
dc98940872 Add missing docs for Encoding class
Signed-off-by: Michal Čihař <michal@cihar.com>
2016-03-08 15:04:37 +01:00
Michal Čihař
d846b2e5d5 Prefer mbstring for autodetection as it's usually present these days
Signed-off-by: Michal Čihař <michal@cihar.com>
2016-03-08 14:59:30 +01:00
Michal Čihař
5929b3edf5 Remove not needed use
Signed-off-by: Michal Čihař <michal@cihar.com>
2016-03-08 14:59:13 +01:00
Michal Čihař
3bda9a03b9 Move Kanji encoding handling to Encoding class
Issue #11731

Signed-off-by: Michal Čihař <michal@cihar.com>
2016-03-08 14:55:41 +01:00
Michal Čihař
28d15ebb8c Add method for checking if encoding conversion is supported
Signed-off-by: Michal Čihař <michal@cihar.com>
2016-03-08 14:26:49 +01:00
Michal Čihař
4ed47fc4b4 Move charset conversion to a class
Also removes ancient support for AIX iconv.

Issue #11731

Signed-off-by: Michal Čihař <michal@cihar.com>
2016-03-08 14:05:59 +01:00