Quote:
Originally Posted by Quexos
Ok, like I said this is over my league. Like when you mention "poem" as an element to control some values, it's confusing cause I don't have poetry in my books so why is "poem" an element in css code ?
So I guess I'll stick with the basics of css and your sample code shows that this "svg" code is to be entered right after "body class" so I'll try that and see how it goes
And to answer your question I view my ebooks with "Reader for PC" it's the Sony soft to see epubs.
|
I think it was just a poor explanation of what CSS selectors are.
In CSS, you can reference tags on a page just by typing the tag's name. For example "body" would reference the <body>...</body> element, "p" would reference anything inside <p>...</p> tags, and something like "div" would match anything inside generic <div>...</div> tags.
Tags can have two other identities added to them: IDs and classes. Generally classes are used to apply a common style to many different elements on a page. For example, I could have a div block and a p block with the class "centered-text" applied which, as long as I defined it properly in the CSS, would center the text in
both elements. IDs are usually applied to unique code blocks that need to be identified as a singular entity.
Here's an example of a p block with an ID and a class assigned:
Code:
<p id="preface" class="lead-paragraph">
....
</p>
So that paragraph has an ID of "preface" and a class of "lead-paragraph". It's important to understand that IDs and classes mean nothing until they're defined in the page's CSS.
So, in CSS you reference IDs using the ID prefaced by a # sign, so for the example above we'd reference that p block by defining "#preface" in the CSS. Likewise classes are referenced by the class name prefaced by a ".". In the example above, we could reference that same paragraph by defining ".lead-paragraph" in the CSS.
You do not need to add in the type of block it is in the CSS unless you need to. For example, if I had both p blocks, tables and div's with the class "centered-text" but wanted to specify something
only for the p tags, I could add a CSS reference of "p.centered-text" which says, simply, for all the p blocks with the class centered-text, here are some specifications.
Hope this helps!