error in console on opening aem site edit mode /editor.html/content/sites/sample/en.html

Avatar

Avatar
Validate 1
Employee
tasunil
Employee

Like

1 like

Total Posts

20 posts

Correct reply

0 solutions
Top badges earned
Validate 1
Boost 1
View profile

Avatar
Validate 1
Employee
tasunil
Employee

Like

1 like

Total Posts

20 posts

Correct reply

0 solutions
Top badges earned
Validate 1
Boost 1
View profile
tasunil
Employee

14-12-2020

I am facing one issue, I created a single page website using the samples in AEM 6.5 with sp7 but in the console on opening the html page I am getting, "Refused to apply style from 'http://localhost:4502/etc.clientlibs/settings/wcm/designs/social/console/resources.css' because its MIME type ('') is not a supported stylesheet MIME type, and strict MIME checking is enabled." 

2020-12-14 17_59_14-Window.png

 

 What is the cause of this issue and what can be done to avoid this issue? Any help would be great. Thanks

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar
Establish
MVP
BrianKasingli
MVP

Likes

645 likes

Total Posts

607 posts

Correct reply

239 solutions
Top badges earned
Establish
Ignite 1
Give Back 5
Give Back 3
Give Back 10
View profile

Avatar
Establish
MVP
BrianKasingli
MVP

Likes

645 likes

Total Posts

607 posts

Correct reply

239 solutions
Top badges earned
Establish
Ignite 1
Give Back 5
Give Back 3
Give Back 10
View profile
BrianKasingli
MVP

15-12-2020

@tasunil,

404 not found means that your client library does not exist.

Assuming that you are working on the author as your local development environment, you are logged in as an administrator, accessing /etc.clientlibs/* should not be a problem at all with authentication.

The first thing that caught my eye is, does the client library exist in the JCR? In CRX/DE can you find and resolve, /apps/settings/wcm/designs/social/console/resources.css or /libs/settings/wcm/designs/social/console/resources.css. And is this resource a valid client library?

Secondly, once you locate the resources that generate the client library CSS & JS files, copy the clientlib category. Now, double check if the client library is valid using dumplibs tool, localhost:4502/libs/granite/ui/content/dumplibs.html.

 

 

 

 

 

Answers (3)

Answers (3)

Avatar

Avatar
Validate 1
Employee
tasunil
Employee

Like

1 like

Total Posts

20 posts

Correct reply

0 solutions
Top badges earned
Validate 1
Boost 1
View profile

Avatar
Validate 1
Employee
tasunil
Employee

Like

1 like

Total Posts

20 posts

Correct reply

0 solutions
Top badges earned
Validate 1
Boost 1
View profile
tasunil
Employee

15-12-2020

Hello @BrianKasingli 

 

The css is not present in either of the two locations /apps/settings/wcm/designs/social/console/resources.css or /libs/settings/wcm/designs/social/console/resources.css

I did not understand the meaning of And is this resource a valid client library?

I simply created a single page using Link and on editing i am getting this error. I have added no custom css. 

Also in the dumplibs there is no /libs/settings/wcm/designs/social/

Only the following are present

2020-12-15 23_09_00-mRemoteNG - confCons.xml - aemtestmachine iyJcfpncH4v5rMvdKpVO.png

and no path is present by this wcm/designs/social

What css should be added so that this error goes away?

Thanks

Avatar

Avatar
Validate 1
Employee
tasunil
Employee

Like

1 like

Total Posts

20 posts

Correct reply

0 solutions
Top badges earned
Validate 1
Boost 1
View profile

Avatar
Validate 1
Employee
tasunil
Employee

Like

1 like

Total Posts

20 posts

Correct reply

0 solutions
Top badges earned
Validate 1
Boost 1
View profile
tasunil
Employee

15-12-2020

Hi @sureshd71454102, I tried the following steps, but I am still getting the error in the console, I added the paths in the Apache Sling Authentication Service. i did not understand what is to be done with anonymous user access level. this css i have not added so how can i load a full css. and it is saying that localhost page cannot be found at http://localhost:4502/etc.clientlibs/settings/wcm/designs/social/console/resources.css 4042020-12-15 21_37_13-mRemoteNG - confCons.xml - aemtestmachine iyJcfpncH4v5rMvdKpVO.png

Avatar

Avatar
Ignite 1
MVP
SureshDhulipudi
MVP

Likes

163 likes

Total Posts

174 posts

Correct reply

49 solutions
Top badges earned
Ignite 1
Give Back 5
Give Back 3
Give Back 10
Give Back
View profile

Avatar
Ignite 1
MVP
SureshDhulipudi
MVP

Likes

163 likes

Total Posts

174 posts

Correct reply

49 solutions
Top badges earned
Ignite 1
Give Back 5
Give Back 3
Give Back 10
Give Back
View profile
SureshDhulipudi
MVP

15-12-2020

1) can you check Apache Sling Authentication Service and add allow specific routes to be accessible without authorization:

-/libs/granite/ui

-/apps/granite/core/content

This will enable the CSS.

2) Anonymous user access level

3) Check the .css modified files syntax

4) Minification of css files also some times gives error, try to load full css file / check it by accessing directly with url https://localhost:4502/<path>/file.css