CSS are not loading on domain

Created:

2016-11-16 13:12:16 UTC

Modified:

2017-04-24 11:43:13 UTC

0

Was this article helpful?


Have more questions?

Submit a request

CSS are not loading on domain

Applicable to:

  • Plesk 11.5 for Linux
  • Plesk 12.0 for Linux

Symptoms

  1. CSS is not currently loading on domain example.com . While Apache can view the files for some reason nginx cannot:

    1.1.1.1 - - [23/Aug/2013:16:41:36 -0500] "GET /wp-content/themes/OU%20Membership/style-subscription.css HTTP/1.0" 200 286 "-" "Mozilla/5.0 (Windows NT 6.1; WOW64; rv:22.0) Gecko/20100101 Firefox/22.0"
    1.1.1.1 - - [23/Aug/2013:16:41:36 -0500] "GET /style-subscription.css HTTP/1.0" 200 254 "-" "Mozilla/5.0 (Windows NT 6.1; WOW64; rv:22.0) Gecko/20100101 Firefox/22.0"
    1.1.1.1 - - [23/Aug/2013:16:41:36 -0500] "GET /internal-nginx-static-locationstyle-subscription.css HTTP/1.0" 404 77047 "-" "Mozilla/5.0 (Windows NT 6.1; WOW64; rv:22.0) Gecko/20100101 Firefox/22.0"
    1.1.1.1 - - [23/Aug/2013:16:41:36 -0500] "GET /internal-nginx-static-locationwp-content/themes/OU%20Membership/style-subscription.css HTTP/1.0" 404 77047 "-" "Mozilla/5.0 (Windows NT 6.1; WOW64; rv:22.0) Gecko/20100101 Firefox/22.0"
  2. There is custom Apache directives in Home > Subscriptions > example.com > Web Server Settings > Additional directives for HTTP section.

Cause

Extra slash sign in argument for DocumentRoot parameter in custom Apache directives.

Resolution

Go to Subscriptions > example.com > Web Server Settings > Additional directives for HTTP and change the value DocumentRoot as follows:

Before

DocumentRoot "/var/www/vhosts/example.com/httpdocs/"

After

DocumentRoot "/var/www/vhosts/example.com/httpdocs"
Have more questions? Submit a request
Please sign in to leave a comment.