Title: php8 error
Last modified: February 8, 2021

---

# php8 error

 *  Resolved [funkyj4ever](https://wordpress.org/support/users/funkyj4ever/)
 * (@funkyj4ever)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/php8-error-2/)
 * Hi,
    When i enable php 8 i get a error when uploading a svg file. ”
 * Image post-processing failed because the server was busy or does not have enough
   resources. Uploading a smaller image can help. Recommended maximum size is 2500
   pixels.
    ” When i switch back to php 7.4 it works again.
 * Wordpress caught this error.
 * Foutdetails
    =========== Een fout van het type E_ERROR werd veroorzaakt op regelnummer
   249 van het bestand /www/fotobooth_592/public/wp-content/plugins/safe-svg/lib/
   vendor/enshrined/svg-sanitize/src/Sanitizer.php. Foutmelding: Uncaught Error:
   Call to undefined function enshrined\svgSanitize\libxml_disable_entity_loader()
   in /www/fotobooth_592/public/wp-content/plugins/safe-svg/lib/vendor/enshrined/
   svg-sanitize/src/Sanitizer.php:249 Stack trace: #0 /www/fotobooth_592/public/
   wp-content/plugins/safe-svg/lib/vendor/enshrined/svg-sanitize/src/Sanitizer.php(
   201): enshrined\svgSanitize\Sanitizer->setUpBefore() #1 /www/fotobooth_592/public/
   wp-content/plugins/safe-svg/safe-svg.php(142): enshrined\svgSanitize\Sanitizer-
   >sanitize(‘

Viewing 4 replies - 1 through 4 (of 4 total)

 *  Plugin Author [Benbodhi](https://wordpress.org/support/users/benbodhi/)
 * (@benbodhi)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/php8-error-2/#post-14022698)
 * Hi there,
 * Thanks for reporting this.
 * I have it running on php 8 I believe in my test environment. But I’ll make sure
   to do some php 8 specific testing asap.
 * Thanks again!
 *  Plugin Author [Benbodhi](https://wordpress.org/support/users/benbodhi/)
 * (@benbodhi)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/php8-error-2/#post-14022700)
 * Oh, so your errors relate to safe svg I think, not my plugin, svg support.
 * Try disabling safe svg plugin and see how that goes.
 * I’ll still do some testing anyway though.
 *  [donbowman](https://wordpress.org/support/users/donbowman/)
 * (@donbowman)
 * [5 years, 3 months ago](https://wordpress.org/support/topic/php8-error-2/#post-14130358)
 * I find an error on php8.0
 * `wp_localize_script($handle = 'bodhi_svg_inline', $object_name = 'ForceInlineSVGActive',
   $l10n = 'false') /app/wp-content/plugins/svg-support/functions/enqueue.php:145"`
 * I was trying to find the code to fork it and fix, but the github [https://github.com/wp-plugins/svg-support](https://github.com/wp-plugins/svg-support)
   doesn’t match the current version. Am i missing something?
 * The stack trace is below:
 * PHP message: PHP Warning: Only the first byte will be assigned to the string 
   offset in /app/wp-includes/class.wp-scripts.php on line 492″
    PHP message: PHP
   Stack trace:” PHP message: PHP 1. {main}() /app/index.php:0″ PHP message: PHP
   2. require() /app/index.php:17″ PHP message: PHP 3. require_once() /app/wp-blog-
   header.php:19″ PHP message: PHP 4. include() /app/wp-includes/template-loader.
   php:106″ PHP message: PHP 5. get_header($name = *uninitialized*, $args = *uninitialized*)/
   app/wp-content/themes/neve/page.php:10″ PHP message: PHP 6. locate_template($
   template_names = [0 => ‘header.php’], $load = TRUE, $require_once = TRUE, $args
   = []) /app/wp-includes/general-template.php:48″ PHP message: PHP 7. load_template(
   $_template_file = ‘/app/wp-content/themes/neve/header.php’, $require_once = TRUE,
   $args = []) /app/wp-includes/template.php:676″ PHP message: PHP 8. require_once()/
   app/wp-includes/template.php:730″ PHP message: PHP 9. wp_head() /app/wp-content/
   themes/neve/header.php:22″ PHP message: PHP 10. do_action($tag = ‘wp_head’) /
   app/wp-includes/general-template.php:3005″ PHP message: PHP 11. WP_Hook->do_action(
   $args = [0 => ”]) /app/wp-includes/plugin.php:484″ PHP message: PHP 12. WP_Hook-
   >apply_filters($value = ”, $args = [0 => ”]) /app/wp-includes/class-wp-hook.php:
   311″ PHP message: PHP 13. wp_enqueue_scripts(”) /app/wp-includes/class-wp-hook.
   php:287″ PHP message: PHP 14. do_action($tag = ‘wp_enqueue_scripts’) /app/wp-
   includes/script-loader.php:2004″ PHP message: PHP 15. WP_Hook->do_action($args
   = [0 => ”]) /app/wp-includes/plugin.php:484″ PHP message: PHP 16. WP_Hook->apply_filters(
   $value = ”, $args = [0 => ”]) /app/wp-includes/class-wp-hook.php:311″ PHP message:
   PHP 17. bodhi_svgs_inline(”) /app/wp-includes/class-wp-hook.php:287″ PHP message:
   PHP 18. wp_localize_script($handle = ‘bodhi_svg_inline’, $object_name = ‘ForceInlineSVGActive’,
   $l10n = ‘false’) /app/wp-content/plugins/svg-support/functions/enqueue.php:145″
   PHP message: PHP 19. WP_Scripts->localize($handle = ‘bodhi_svg_inline’, $object_name
   = ‘ForceInlineSVGActive’, $l10n = ‘false’) /app/wp-includes/functions.wp-scripts.
   php:221″
 *  Plugin Author [Benbodhi](https://wordpress.org/support/users/benbodhi/)
 * (@benbodhi)
 * [5 years, 2 months ago](https://wordpress.org/support/topic/php8-error-2/#post-14209787)
 * Hi [@donbowman](https://wordpress.org/support/users/donbowman/)
    Sorry for the
   late reply!
 * Yeah, that repo was just set up to test some update procedures a few years ago.
   It’s hosted just in WordPress’ SVN repo.
 * I’m hoping to get one time to work on the plugin very soon and will address this
   and many other things.
 * If you wanted to play with the code in the meantime, you can download it direct
   from the WordPress.org repo for the time being.

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘php8 error’ is closed to new replies.

 * ![](https://ps.w.org/svg-support/assets/icon.svg?rev=3554681)
 * [SVG Support](https://wordpress.org/plugins/svg-support/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/svg-support/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/svg-support/)
 * [Active Topics](https://wordpress.org/support/plugin/svg-support/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/svg-support/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/svg-support/reviews/)

 * 4 replies
 * 3 participants
 * Last reply from: [Benbodhi](https://wordpress.org/support/users/benbodhi/)
 * Last activity: [5 years, 2 months ago](https://wordpress.org/support/topic/php8-error-2/#post-14209787)
 * Status: resolved