CSS for Articles
AnsweredI’m trying to figure out how to apply style to html elements in articles published in Guide. For example, I’d like to add a border to images, as well as vertically align text to the top of the image. I know how to write the css, but I don’t know how to apply it using the style.css file.
I found the section for /*****Article*****/ in style.css. All the rules begin with a .article selector.
First of all, do these rules apply to articles found in Guide?
If so, does any rule with the .article selector automatically apply to articles, or do I have to add a class=”article” call somewhere?
Can it be as simple as writing .article img{ border = 2px solid black;} to affect all images added to an article? It would be nice if it were that simple, but it does not seem to work for me.
If all my assumptions are wrong, would someone please direct me to resources that will clarify matters? I’d like all my articles to have a consistent style without having to code every single element.
Thank you in advance.
-
I figured it out. It does, in fact, work for me. I didn't realize I had to open the actual article to see the changes.
-
Thanks for letting us know, Michael. Glad you got it figured out!
Please sign in to leave a comment.
2 Comments