• Resolved Marian Kadanka

    (@mariankadanka)


    Hi,

    we have accidentally uploaded non-valid SVG file, which is actually HTML, into the WordPress media library. Media library grid view (AJAX variant) is broken since then, AJAX call “query-attachments” returns error, and there are PHP warnings in PHP error log:

    [19-Nov-2021 13:43:03 UTC] PHP Warning:  SimpleXMLElement::__construct(): Entity: line 6: parser error : Opening and ending tag mismatch: hr line 5 and body in /data/www/stageserver.union.sk/wp-content/plugins/elementor/core/files/assets/svg/svg-handler.php on line 630
    [19-Nov-2021 13:43:03 UTC] PHP Warning:  SimpleXMLElement::__construct(): </body> in /data/www/stageserver.union.sk/wp-content/plugins/elementor/core/files/assets/svg/svg-handler.php on line 630
    [19-Nov-2021 13:43:03 UTC] PHP Warning:  SimpleXMLElement::__construct():        ^ in /data/www/stageserver.union.sk/wp-content/plugins/elementor/core/files/assets/svg/svg-handler.php on line 630
    [19-Nov-2021 13:43:03 UTC] PHP Warning:  SimpleXMLElement::__construct(): Entity: line 7: parser error : Opening and ending tag mismatch: body line 3 and html in /data/www/stageserver.union.sk/wp-content/plugins/elementor/core/files/assets/svg/svg-handler.php on line 630
    [19-Nov-2021 13:43:03 UTC] PHP Warning:  SimpleXMLElement::__construct(): </html> in /data/www/stageserver.union.sk/wp-content/plugins/elementor/core/files/assets/svg/svg-handler.php on line 630
    [19-Nov-2021 13:43:03 UTC] PHP Warning:  SimpleXMLElement::__construct():        ^ in /data/www/stageserver.union.sk/wp-content/plugins/elementor/core/files/assets/svg/svg-handler.php on line 630
    [19-Nov-2021 13:43:03 UTC] PHP Warning:  SimpleXMLElement::__construct(): Entity: line 8: parser error : Premature end of data in tag html line 1 in /data/www/stageserver.union.sk/wp-content/plugins/elementor/core/files/assets/svg/svg-handler.php on line 630
    [19-Nov-2021 13:43:03 UTC] PHP Warning:  SimpleXMLElement::__construct():  in /data/www/stageserver.union.sk/wp-content/plugins/elementor/core/files/assets/svg/svg-handler.php on line 630
    [19-Nov-2021 13:43:03 UTC] PHP Warning:  SimpleXMLElement::__construct(): ^ in /data/www/stageserver.union.sk/wp-content/plugins/elementor/core/files/assets/svg/svg-handler.php on line 630
    [19-Nov-2021 13:43:03 UTC] PHP Warning:  SimpleXMLElement::__construct(): Entity: line 6: parser error : Opening and ending tag mismatch: hr line 5 and body in /data/www/stageserver.union.sk/wp-content/plugins/elementor/core/files/assets/svg/svg-handler.php on line 630
    [19-Nov-2021 13:43:03 UTC] PHP Warning:  SimpleXMLElement::__construct(): </body> in /data/www/stageserver.union.sk/wp-content/plugins/elementor/core/files/assets/svg/svg-handler.php on line 630
    [19-Nov-2021 13:43:03 UTC] PHP Warning:  SimpleXMLElement::__construct():        ^ in /data/www/stageserver.union.sk/wp-content/plugins/elementor/core/files/assets/svg/svg-handler.php on line 630
    [19-Nov-2021 13:43:03 UTC] PHP Warning:  SimpleXMLElement::__construct(): Entity: line 7: parser error : Opening and ending tag mismatch: body line 3 and html in /data/www/stageserver.union.sk/wp-content/plugins/elementor/core/files/assets/svg/svg-handler.php on line 630
    [19-Nov-2021 13:43:03 UTC] PHP Warning:  SimpleXMLElement::__construct(): </html> in /data/www/stageserver.union.sk/wp-content/plugins/elementor/core/files/assets/svg/svg-handler.php on line 630
    [19-Nov-2021 13:43:03 UTC] PHP Warning:  SimpleXMLElement::__construct():        ^ in /data/www/stageserver.union.sk/wp-content/plugins/elementor/core/files/assets/svg/svg-handler.php on line 630
    [19-Nov-2021 13:43:03 UTC] PHP Warning:  SimpleXMLElement::__construct(): Entity: line 8: parser error : Premature end of data in tag html line 1 in /data/www/stageserver.union.sk/wp-content/plugins/elementor/core/files/assets/svg/svg-handler.php on line 630
    [19-Nov-2021 13:43:03 UTC] PHP Warning:  SimpleXMLElement::__construct():  in /data/www/stageserver.union.sk/wp-content/plugins/elementor/core/files/assets/svg/svg-handler.php on line 630
    [19-Nov-2021 13:43:03 UTC] PHP Warning:  SimpleXMLElement::__construct(): ^ in /data/www/stageserver.union.sk/wp-content/plugins/elementor/core/files/assets/svg/svg-handler.php on line 630

    When the offending file is removed from the media library, or Elementor is deactivated, everything works well.

    Invalid SVG file: https://kadanka.net/info-24-2.svg.zip

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘invalid SVG file uploaded breaks media library’ is closed to new replies.