Hi everyone,
First time poster here. I would greatly appreciate your input.
I have a client library reference which appears on several of my site's pages:
<html>
<head>
...
<link rel="stylesheet" href="/libs/wcm/foundation/components/page/responsive.css" type="text/css">
...
</head>
...
</html>
The call to responsive.css is being blocked by the dispatcher because, per Adobe documentation, it is apparently bad practice to expose /libs/*
Going down the rabbit hole of page -> template -> template type -> component has led me to:
/libs/wcm/foundation/components/page/author.html line 22:
<sly data-sly-test="${wcmInit.templateCategories.length > 0}" data-sly-call="${clientLib.css @ categories=wcmInit.templateCategories}" />
It seems that templateCategories is non-zero, invoking a call to clientLib.css which eventually places the aforementioned reference on the page head.
My issue is not that responsive.css (category: wcm.foundation.components.page.responsive) is on the page, it is that the client library is not being proxied through /etc.clientlibs and is therefore inaccessible via the dispatcher.
Can anyone please point me in the right direction? This issue only appears on some environments, suggesting it is configuration-related.
Thanks in advance!
Solved! Go to Solution.
Views
Replies
Total Likes
Hi @zeevd,
As @Shashi_Mulugu suggested, this clientlib is meant for authoring purposes and if authors are accessing AEM via Dispatcher then your Dispatcher should allow all paths (or you will have many other problems too).
However, if you wish to expose a clientlib under /libs in a Publisher witha Dispatcher that prevents access to /libs, then the clientlib must have allowProxy="{Boolean}true" set on it. This will cause AEM to fetch it under /etc.clientlibs rather than /libs
@zeevd Thank you for posting your query in Communities. Can you please confirm if the AEM instance you are seeing this issue is in Author or Publisher?
In general via template, author.html file will be included in author side to support editing capabilities and this file should not be loaded on publisher.
So if author, make sure you have to allow everything via dispatcher including/libs/..
If in publishers, make sure you not include author.html.
Hi @zeevd,
As @Shashi_Mulugu suggested, this clientlib is meant for authoring purposes and if authors are accessing AEM via Dispatcher then your Dispatcher should allow all paths (or you will have many other problems too).
However, if you wish to expose a clientlib under /libs in a Publisher witha Dispatcher that prevents access to /libs, then the clientlib must have allowProxy="{Boolean}true" set on it. This will cause AEM to fetch it under /etc.clientlibs rather than /libs
Views
Replies
Total Likes
Views
Likes
Replies
Views
Likes
Replies