Gossamer Forum
Home : Products : Gossamer Links : Discussions :

"category" style in CSS 2.99

Quote Reply
"category" style in CSS 2.99
I am having the hardest time changing 1 style in custom.css for luna templates.
The style in question here is "category".

How do I override "category" style as used in cool.html, new.html and search results?
Pertaining specifically to per build_new_gb and build_cool_gb.
This code is from cool.html:

Code:
<%loop link_results_loop~%>
<p class="category"><%Links::Utils::format_title($title_loop,
separator => $category_separator, no_escape_separator => $no_escape_category_separator,
include_home => 0, link_type => 1)%></p>
<%include link.html%>
<%~endloop%>

I have created the following style:
#cool #content a {
color: #ffffff;
font-size: 12px;
font-weight: bold;
background-color: #808080;
padding: 2px;
border: 2px solid #4682B4;
}

It can be seen in use here:
http://www.supportmusicians.com/cgi-bin/links/page.cgi?g=Cool%2F;t=luna;d=1

I would like the category "Band Websites" (when used as a divider) to span the whole width of the page.

It seems to me there should be a separate style for category divider bar as used per build_new_gb and build_cool_gb.

I am still learning this stuff, and I tried diff combinations of:
#cool #content a {
properties...
}
and...
#cool #content #categories a {...}

The only on I could get working is
#cool #content a {...}
but as you can see, it does ALL "content" links.

I want a style for: cool.html/div id=content/p class=categories/a
This would be the "groupbar" as mentioned above.

I hope this makes some sense.

PS I know a can wrap "dd", or "dt" around the code above and in the style to only do the one link as oppossed to ALL links in "content". But I didn't want to edit the template :-)

Besides, I do not understand what "dd", "dt", and "dl" are used for really?
I have searched css manual etc... before asking.

Thanks,
Chris
RGB World, Inc. - Software &amp; Web Development.
rgbworld.com

Last edited by:

rgbworld: Mar 26, 2005, 9:34 AM
Quote Reply
Re: [rgbworld] "category" style in CSS 2.99 In reply to
Remember there's a difference between the element id and class attributes. id's are usually only given to items on a page which will only occur once (eg. a header or footer) since an id can only be used once in html. classes are given to everything else. In css, you reference an id by #id_name, while with a class its .class_name. So in this case, category is a class, so to style it, you should use something like:
Code:
.category {
...
}

In Reply To:
I would like the category "Band Websites" (when used as a divider) to span the whole width of the page.
p elements are block elements so it already spans the entire width. You can put a border-bottom/top on it to make it divide things up.

In Reply To:
Besides, I do not understand what "dd", "dt", and "dl" are used for really?
They are definition lists

Adrian