From: Nik Okuntseff Date: Wed, 14 Nov 2018 23:57:41 +0000 (+0000) Subject: Improved new import so that it does not flood the output with multiple XML errors. X-Git-Tag: timetracker_1.19-1~647 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=af4d194c7beb4020c7aff5f8c9eb36156b9b407e;p=timetracker.git Improved new import so that it does not flood the output with multiple XML errors. --- diff --git a/WEB-INF/lib/ttOrgImportHelper.class.php b/WEB-INF/lib/ttOrgImportHelper.class.php index 77458cfa..96ac5708 100644 --- a/WEB-INF/lib/ttOrgImportHelper.class.php +++ b/WEB-INF/lib/ttOrgImportHelper.class.php @@ -525,7 +525,7 @@ class ttOrgImportHelper { // Read and parse the content of the file. During parsing, startElement is called back for each tag. $file = fopen($filename, 'r'); - while ($data = fread($file, 4096)) { + while (($data = fread($file, 4096)) && $this->errors->no()) { if (!xml_parse($parser, $data, feof($file))) { $this->errors->add(sprintf($i18n->get('error.xml'), xml_get_current_line_number($parser), @@ -554,7 +554,7 @@ class ttOrgImportHelper { // Read and parse the content of the file. During parsing, startElement is called back for each tag. $file = fopen($filename, 'r'); - while ($data = fread($file, 4096)) { + while (($data = fread($file, 4096)) && $this->errors->no()) { if (!xml_parse($parser, $data, feof($file))) { $this->errors->add(sprintf($i18n->get('error.xml'), xml_get_current_line_number($parser), diff --git a/WEB-INF/templates/footer.tpl b/WEB-INF/templates/footer.tpl index 16196a60..1f8ef090 100644 --- a/WEB-INF/templates/footer.tpl +++ b/WEB-INF/templates/footer.tpl @@ -12,7 +12,7 @@
-
 Anuko Time Tracker 1.18.12.4424 | Copyright © Anuko | +  Anuko Time Tracker 1.18.12.4425 | Copyright © Anuko | {$i18n.footer.credits} | {$i18n.footer.license} | {$i18n.footer.improve}