Site is loaded without .css files

Refers to:

  • Plesk 11.5 for Windows
  • Plesk 12.5 for Windows

Created:

2016-11-16 12:59:42 UTC

Modified:

2016-12-21 19:42:57 UTC

0

Was this article helpful?


Have more questions?

Submit a request

Site is loaded without .css files

Symptoms

  • Site is loaded without .css files.

And/Or

  • An attempt to open IIS > Sites > example.com > MIME Types for domain fails with error:
    ---------------------------
    MIME Types
    ---------------------------
    There was an error while performing this operation.

    Details:

    Filename: \\\\?\\C:\\Windows\\system32\\inetsrv\\config\\applicationHost.config

    Line number: 11979

    Error: Cannot add duplicate collection entry of type 'mimeMap' with unique key attribute 'fileExtension' set to '.woff'

Cause

Already existing records in C:\\Windows\\System32\\inetsrv\\config\\applicationHost.config or .css extension is not allowed in custom C:\\inetpub\\vhosts\\example.com\\httpdocs\\Web.config file.

Resolution

In case of custom C:\\inetpub\\vhosts\\example.com\\httpdocs\\Web.config file, review its code and make sure that .css extension is allowed.

If the following (or similar) error is shown in Failed Request Tracing:

Cannot add duplicate collection entry of type 'mimeMap' with unique key attribute 'fileExtension' set to '.woff'

As a temporary solution you could add the line below before duplicate mimeMap element in C:\\inetpub\\vhosts\\example.com\\httpdocs\\Web.config file:

<remove fileExtension=".woff" />

After that, review C:\\inetpub\\vhosts\\example.com\\httpdocs\\Web.config file and make sure that mimeMap element is not already defined in C:\\Windows\\System32\\inetsrv\\config\\applicationHost.config .

Otherwise, remove the site cache and reconfigure domain:

"%plesk_bin%\\websrvmng" --remove-sites-cache

"%plesk_cli%\\repair" --reconfigure-web-site -web-site-name example.com

If it does not help:

  1. Back up the current IIS configuration using the following command in cmd.exe :

    %windir%\\system32\\inetsrv\\appcmd.exe add backup "My Backup Name"
  2. Open %windir%\\system32\\inetsrv\\config\\applicationHost.config file in text editor and remove the line specified in the symptoms (Line number: 11979):

    <mimeMap fileExtension=".woff" mimeType="font/x-woff" />
  3. Reconfigure the domain:

    "%plesk_cli%\\repair" --reconfigure-web-site -web-site-name example.com
Have more questions? Submit a request
Please sign in to leave a comment.