jhass / nextcloud-keeweb

Integrate Keeweb into Nextcloud
Other
415 stars 48 forks source link

Keeweb Refused to apply style from 'https://home.url/css/core/7681-81b1-server.css?v=9570003a5acc6baaa34e77da55a31fcf-98e98dae-30' because its MIME type ('text/html') is not a supported stylesheet MIME type, and strict MIME checking is enabled. #150

Open zyonbv opened 4 years ago

zyonbv commented 4 years ago

Hello Everybody,

I have the following issue only when using chrome. I have tried multiple devices running Chrome and I get the same result:

Refused to apply style from 'https://home.url/css/core/7681-81b1-server.css?v=9570003a5acc6baaa34e77da55a31fcf-98e98dae-30' because its MIME type ('text/html') is not a supported stylesheet MIME type, and strict MIME checking is enabled.

Nextcloud version: 18.0.6 Keeweb version: 0.6.2 All checks passed. nginx version: nginx/1.18.0

The problem is when only accessing the Keeweb from the Icon.

If I press on a *.kdbx eveything is normal.

2020-06-30 16_13_57-Keeweb - bCloud ro

Thank you, Ionut

SuperSandro2000 commented 4 years ago

What is returned if you visit the path? Can you open it in the browser and show the header?

zyonbv commented 4 years ago

Hey, I did check the paths, because I realized that there are 4 x 404 requests. All of them appear 404 Not Found.

Please see screenshots below. I did the working way and realized the requests are the same but the IDs are different. I mean the one marked by me.

image

image

SuperSandro2000 commented 4 years ago

The problem is that keepweb tries to load files which should be css files but they aren't so your browser does not interpret them as css to prevent attacks.

zyonbv commented 4 years ago

Funny thing is that when opening a kdbx file everything checks ok. Only the css files have different IDs.

zyonbv commented 4 years ago

I did solve the problem by Going in Dev Console F12> Application> Clear Storage > Clear site data. Some IDs for those css files remained cached and they were not reachable. I did play with Talk for Nextcloud and Dark Breeze Theme. I am thinking that was the reason.

Thanks for your support.

Slug-V commented 4 years ago

I reproduced this in 18.0.4 -> 19.0.0 update. I removed browser(Chrome) cache using "Clear browsing data…" and the problem is solved.

Amiremoonam commented 4 years ago

Hey i'd a same issue and i edited my css path in my home.ejs and i solved it .

before : <link rel="stylesheet" href="css/styles.css">

after 👍
<link rel="stylesheet" href="/css/styles.css">

i forgot to put / before my css/style.css path and after all it got solved

hope to help you a little ...