MDL-31301 use static textlib methods

This commit is contained in:
Petr Skoda
2012-03-03 11:46:13 +01:00
parent 5bbf3cb72b
commit f8311defeb
53 changed files with 191 additions and 329 deletions
+2 -4
View File
@@ -84,11 +84,9 @@ class csv_import_reader {
$this->close();
$this->_error = null;
$textlib = textlib_get_instance();
$content = $textlib->convert($content, $encoding, 'utf-8');
$content = textlib::convert($content, $encoding, 'utf-8');
// remove Unicode BOM from first line
$content = $textlib->trim_utf8_bom($content);
$content = textlib::trim_utf8_bom($content);
// Fix mac/dos newlines
$content = preg_replace('!\r\n?!', "\n", $content);
// is there anyting in file?