Expand my Community achievements bar.

Don’t miss the AEM Skill Exchange in SF on Nov 14—hear from industry leaders, learn best practices, and enhance your AEM strategy with practical tips.
SOLVED

New to AEM - why aren't my css classes being used?

Avatar

Level 2

I've been following the AEM 6.1 tutorial found here:

    https://docs.adobe.com/docs/en/aem/6-1/develop/the-basics/website.html

I'm running into a question that is puzzling to me. I create all the way through to making my own 'body.jsp' file, and add the stuff they recommend into it. But I notice that when I open the page (by double-clicking it from the AEM WCM tool) and my page pops up in the editor, it doesn't seem to include anything I personally add to the content (like a 'class="foo"' tag to a <div>, or even HTML comments like <!-- RDW TEST -->).

So my question is really sort of generic - how can I build a site where I have complete control over the css, javascript, and content? And then how do I retrofit the AEM editor functionality into that site?

1 Accepted Solution

Avatar

Correct answer by
Administrator

Hi 

This is great the things are working now.

But for your reference, please have a look at these few reference Helpx articles in which we are creating component/Using Apis etc but also using CSS.

Link:- https://helpx.adobe.com/experience-manager/using/custom_columns.html

Link:- https://helpx.adobe.com/experience-manager/using/custom-carousel-components.html

Link:- https://helpx.adobe.com/experience-manager/using/custom-sling-servlets.html

 

Please have a look at the all articles list here:-

Link:- https://helpx.adobe.com/experience-manager/topics/how-to.html

 

I hope this would be useful for you.

Thanks and Regards

Kautuk Sahni



Kautuk Sahni

View solution in original post

3 Replies

Avatar

Level 2

Nevermind, this appears to be only an artifact of the AEM page editor tool. If I remove the /editor.html/ from the URL and just look at the page directly - it shows up like I expect. This does beg a new question, but I'll put that in a new topic.

Avatar

Level 10

To use JS files and CSS, tou need to use clientlibs. The JS and CSS files go into the clientlib.

Avatar

Correct answer by
Administrator

Hi 

This is great the things are working now.

But for your reference, please have a look at these few reference Helpx articles in which we are creating component/Using Apis etc but also using CSS.

Link:- https://helpx.adobe.com/experience-manager/using/custom_columns.html

Link:- https://helpx.adobe.com/experience-manager/using/custom-carousel-components.html

Link:- https://helpx.adobe.com/experience-manager/using/custom-sling-servlets.html

 

Please have a look at the all articles list here:-

Link:- https://helpx.adobe.com/experience-manager/topics/how-to.html

 

I hope this would be useful for you.

Thanks and Regards

Kautuk Sahni



Kautuk Sahni