Wordpress Themes - WP Forum at BFA

Wordpress Themes - WP Forum at BFA (http://forum.bytesforall.com/index.php)
-   Center area post/pages (http://forum.bytesforall.com/forumdisplay.php?f=32)
-   -   CSS documentation (http://forum.bytesforall.com/showthread.php?t=14046)

tunturiflyer May 5, 2011 12:28 PM

CSS documentation
 
Miles1SW kindly suggested the answer below to create a different background for pages and posts.

The bit I don't understand is the type-page and type-post class selectors.

Would appreciate a link to any documentation on class selectors available in ATO.

Or, would be good to know if such class selectors are only discoverable by working through the code.

Much appreciated.

Here's Miles' answer:

you perhaps could use the following in ATO>Add HTML/CSS Inserts>CSS Inserts
HTML Code:

.type-page {
background: #fff !important;
{
.type-post {
background: #greenhexcode !important;
}

lmilesw May 5, 2011 12:42 PM

You would just put that exact code in ATO>Add HTML/CSS Inserts>CSS Inserts and change the colors to what you want.

tunturiflyer May 5, 2011 01:37 PM

Hi Miles,
Indeed, many thanks, I did that, and it worked pretty well.

I would like to understand how it works, and how to create similar solutions by modifying the CSS.

So far, I haven't found any documentation on the type-page class selector, and I would guess there are a bunch of other class selectors that are also available. Admittedly, I haven't quite finished Eric Meyer's CSS book, but I couldn't find anything on the web either.

Essentially the deeper question is, if I may be so bold as to sit at your feet and learn:

"how on earth did you discover your excellent solution in the first place?"

lmilesw May 5, 2011 03:49 PM

For much of what I do I use the Firebug addon for Firefox. Then I look for the selectors. That can take some familiarity with what you are looking at though. In your case I just use the Firebug inspector to "look" at a post and a page and noted the class selectors. Then I just did a virtual test, again with Firebug, with those selectors and tried display:none and it worked.

This is much easier to do than explain but after awhile as you become more familiar with what you are looking at things come easier.

tunturiflyer May 5, 2011 04:16 PM

Much appreciated Miles. I spent ages looking for some documentation, as I thought type-page and type-post might be documented somewhere.

It's really useful just knowing what I need to master.

juggledad May 5, 2011 05:16 PM

FYI, there are no 'standard' classes and IDs anyone written a theme or plugin or a post using the HTML editor can create their own. I could code
HTML Code:

<div class="juggledad">Hello World</div>
and its valid. WordPress has started using some standard classes for menus and posts but each theme can add their own.


All times are GMT -6. The time now is 03:24 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.