Support » Plugin: Swift Performance Lite » [Error] Loading remote file (http://desktop-scripts.js) failed.

  • Resolved sanjaisc



    First of all let me start by saying that Swift Performance is an awesome caching plugin and possibly ranks among the best caching plugins available. Keep it up guys!

    I have a strange problem on several websites hosted with A2Hosting. When opening pages on Chrome (Desktop) there is no error. But if I open the same page on Chrome (Mobile) or Firefox (Desktop) I get an error:

    [Error] Loading remote file (http://desktop-scripts.js) failed. Error: cURL error 6: Could not resolve host: desktop-scripts.js

    The specified file is located at:

    The Cache path specified in Swift Performance is: /home/sanjaisc/public_html/ccapitalist/wp-content/cache/ which is correct.

    The rewrite rules in .htaccess are as follows:

    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteCond %{REQUEST_METHOD} !POST
    RewriteCond %{QUERY_STRING} ^$
    RewriteCond %{HTTP:Cookie} !^.*(wordpress_logged_in).*$
    RewriteCond %{REQUEST_URI} !^/wp-content/cache/swift-performance/([^/]*)/assetproxy
    RewriteCond /home/sanjaisc/public_html/ccapitalist/wp-content/cache/swift-performance/%{HTTP_HOST}%{REQUEST_URI}/desktop/unauthenticated/index.html -f
    RewriteRule (.*) wp-content/cache/swift-performance/%{HTTP_HOST}%{REQUEST_URI}/desktop/unauthenticated/index.html [L]

    <IfModule mod_headers.c>
    RewriteRule (.*)/desktop/unauthenticated/(.*).html – [E=cache_base_uri:$1]
    Header set Link “</%{cache_base_uri}e/css/desktop-full.css>; rel=preload; as=style,</%{cache_base_uri}e/js/desktop-scripts.js>; rel=preload; as=script” env=cache_base_uri


    Any pointers as to what could be going wrong will be highly appreciated.

    The page I need help with: [log in to see the link]

Viewing 1 replies (of 1 total)
  • Plugin Contributor Fred


    Thank you for your kind words.

    This is probably caused by an improper order of htaccess rules. Probably you are using a force SSL or force www/non-www rule in .htaccess. Please remove these rules from .htaccess, and insert them in

    Settings→General→Tweaks: Custom .htaccess
    or at least at the top of the .htaccess file.

    Read more about this issue in our FAQ

Viewing 1 replies (of 1 total)
  • The topic ‘[Error] Loading remote file (http://desktop-scripts.js) failed.’ is closed to new replies.