Empty css/js on 1 page (files loading as "/")

Created on 12 May 2023, over 1 year ago

Problem/Motivation

Similar to https://www.drupal.org/project/advagg/issues/3224986 🐛 Missing/empty CSS only on one page Closed: won't fix .

I have about 50+ sites (all use the same theme and have the same features). For some reason, on 1 of them (and only 1) there is a page on the backend where the js/css doesn't load. It's not all js/css files, just a few.

No errors on the network tab at all. If I view the page source, I see this:

<link rel="stylesheet" media="all" href="/sites/site_name_here/files/css/css_saumSBT-sE-epVDsaGD_wRDyJsLJxltrrNWevT73B_0.css" />
<link rel="stylesheet" media="all" href="/" />
<link rel="stylesheet" media="all" href="/sites/site_name_here/files/css/css_gpfh12_OvpJ8ZFCmnKFFkUVpZ1oWi6EEQv21ayue98Y.css" />

Near the bottom of the page I have this:

<script src="/"></script>
<script src="/modules/contrib/ckeditor/vendor/ckeditor.js?v=4.18.0"></script>
<script src="/"></script>

The other working sites show this:

<script src="/sites/site_name_here/files/js/js_Nf02DGL_nxHn7rSaR3QmNX3OiR6D5PYk35zhbuakjzM.js"></script>
<script src="/modules/contrib/ckeditor/vendor/ckeditor.js?v=4.18.0"></script>
<script src="/sites/site_name_here/files/js/js_xalgGszc7jHHMkHnQlXr4FVAq0LRapWIH0xH8KNZF80.js"></script>

I do however see these errors in the console:
"Refused to apply style because its MIME type ('text/html') is not a supported stylesheet MIME type, and strict MIME checking is enabled."
"Refused to execute script because its MIME type ('text/html') is not executable, and strict MIME type checking is enabled."

Which I guess makes sense because of the "/". So no stylesheet/js file is being loaded.

I'm almost positive clearing the cache would work. I'm just more concerned with the how or why this happened.

Perhaps this isn't even an advagg issue either. I'm just looking for an answer as to what could have caused this to occur.

Any ideas? Thanks!

🐛 Bug report
Status

Active

Version

5.0

Component

General CSS/JS

Created by

Live updates comments and jobs are added and updated live.
  • CSS

    It involves the content or handling of Cascading Style Sheets.

Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024