• Resolved TeroSalminen

    (@terosalminen)


    After doing the last W3TC update I cannot upload images/files. Well, I can upload them, they do go to my server but W3TC is not handling CDN (Amazon Cloudfront) responses correctly for some reason.

    Uploading test image does go to my server, example: https://www.rc-thoughts.com/wp-content/uploads/2018/04/cdn_test.png
    it is also uploaded to CDN correctly: https://cdn.rc-thoughts.com/wp-content/uploads/2018/04/cdn_test.png

    However, WP shows me an error with the image-name and simple “HTTP error.”

    Looking at server logs we see what is going on:

    2018/04/28 12:39:47 [error] 2958#2958: *247 FastCGI sent in stderr: "PHP message: PHP Fatal error:  Uncaught Error: Call to undefined function simplexml_load_string() i
    n /wp-content/plugins/w3-total-cache/lib/S3.php:1895
    Stack trace:
    #0 /wp-content/plugins/w3-total-cache/lib/S3.php(1572): S3::getCloudFrontResponse(Object(S3Request))
    #1 /wp-content/plugins/w3-total-cache/CdnEngine_S3_Cf.php(170): S3::listDistributions()
    #2 /wp-content/plugins/w3-total-cache/CdnEngine_S3_Cf.php(149): W3TC\CdnEngine_S3_Cf->invalidate(Array, Array)
    #3 /wp-content/plugins/w3-total-cache/Cdn_Core.php(267): W3TC\CdnEngine_S3_Cf->purge(Array, Array)
    #4 /wp-content/plugins/w3-total-cache/Cdn_Plugin.php(158): W3TC\Cdn_Core->purge(Array, Array)
    #5 /wp-includes/class-wp-hook.php(288): W3TC\Cdn_Plugin->update_attached_file('/w...')
    #6 /wp-includes/plugin.php(203): WP_Hook->apply_filters('/w...', Array)
    #7 /wp-includes/post.php(335): apply_filters('update_attache" while reading response header from upstream, client: xxx.xxx.xxx.xxx, server: www.rc-thoughts.
    com, request: "POST /wp-admin/async-upload.php HTTP/2.0", upstream: "fastcgi://unix:/run/php/php7.1-fpm.sock:", host: "www.rc-thoughts.com"

    Only thing changed on my WP is updated W3TC, purged all caches, updated W3TC’s Nginx-config, restarted both PHP 7.1.16-1 and Nginx /1.13.12

    Since this error also prevent’s me to use the image in post’s this is somewhat serious.

    Any help is appreciated!

    • This topic was modified 8 years, 1 month ago by TeroSalminen.
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘CDN broken – Call to undefined function simplexml_load_string()’ is closed to new replies.