How can I customize the description fonts? I 'm not using the css style sheet so could I customize the description text?
Nov 25, 2002, 9:59 AM
Veteran (1350 posts)
Nov 25, 2002, 9:59 AM
Post #2 of 2
Views: 391
I would go with the CSS! When I first started with Links, I, too, scrapped all the CSS, 'cause I didn't understand it. But boy howdy, it is well worth learning! If you keep it, just go into the stylesheet and find this:
span.descript {
font-size: small;
color: #333333;
background: #FFFFFF;
font-family: "verdana", "arial", "geneva", sans-serif;
}It is pretty obvious what to change. To do it the hard way, look in site_html_templates (you're using templates?), under site_html_print_cat (last routine in the file) for this:
XXXXXXXXXXXXXXX
# Then we print out the name linked, new if it's new, and popular if its popular.
$output .= qq|<dl><dt><strong><a class="link" href="$url">$category_name</a></strong> <small class="numlinks">($numlinks)</small> |;
$output .= qq|<small><sup class="new">new</sup></small>| if (&days_old($mod) < $db_new_cutoff);
$output .= qq|</dt>|;
$output .= qq|<dd><span class="descript">$description </span></dd>| if (!($description =~ /^[\s\n]*$/));
$output .= qq|</dl>|;
}
XXXXXXXXXXXXXXXXX
Where it says <span.....> you can change that to HTML markup. Also, remove the </span>. Did you know that <font> tags are depracated? That means they are no longer part of the "official" HTML code. (Yes, current browsers still support the.) But then, HTML is being pushed aside by XHTML, which will give way to XML...
What I'm saying is, keep up with the current standards, which uses CSS instead of <font> tags. As I convert my site to CSS, I am cutting the length of the source code on some pages just about half! It's much cleaner, faster, easier to read, and MUCH easier to change.
Kind of a long answer to a short question...!
[edit: I added some line breaks to the code above, it was way wide.]
Leonard
aka PerlFlunkie
Code:
/* The link description */ span.descript {
font-size: small;
color: #333333;
background: #FFFFFF;
font-family: "verdana", "arial", "geneva", sans-serif;
}
XXXXXXXXXXXXXXX
# Then we print out the name linked, new if it's new, and popular if its popular.
$output .= qq|<dl><dt><strong><a class="link" href="$url">$category_name</a></strong> <small class="numlinks">($numlinks)</small> |;
$output .= qq|<small><sup class="new">new</sup></small>| if (&days_old($mod) < $db_new_cutoff);
$output .= qq|</dt>|;
$output .= qq|<dd><span class="descript">$description </span></dd>| if (!($description =~ /^[\s\n]*$/));
$output .= qq|</dl>|;
}
XXXXXXXXXXXXXXXXX
Where it says <span.....> you can change that to HTML markup. Also, remove the </span>. Did you know that <font> tags are depracated? That means they are no longer part of the "official" HTML code. (Yes, current browsers still support the.) But then, HTML is being pushed aside by XHTML, which will give way to XML...
What I'm saying is, keep up with the current standards, which uses CSS instead of <font> tags. As I convert my site to CSS, I am cutting the length of the source code on some pages just about half! It's much cleaner, faster, easier to read, and MUCH easier to change.
Kind of a long answer to a short question...!
[edit: I added some line breaks to the code above, it was way wide.]
Leonard
aka PerlFlunkie

