Page 1 of 1
CSS Element Not working on Carl02
Posted: Thu Mar 29, 2007 4:05 pm
by TKS
http://linux-blog.org/index.php?/archiv ... ricks.html
On that page, I've got overflow of my code elements. I've changed things in the CSS for Carl02's style to have scrollbars but they're not appearing.
Code: Select all
code {display:block; font-size:0.7em; background-color:#f8f6f6; overflow:auto;
font-weight:bold; border:1px solid #efefef;padding:4px; }
Any ideas? Upon looking at source for the page, I find that it's calling the class bb-code. I can't find that class. Am I changing things in the wrong place?
Re: CSS Element Not working on Carl02
Posted: Thu Mar 29, 2007 4:10 pm
by garvinhicking
Hi!
the bb code snippet comes from the serendipity_event_bbcode plugin which has its own style. You could copy+paste the output of your current CSS sheet and then put those bb-code classes into your style.css file, which will then make the plugin no longer emit its default styles.
You can then fill your customizations into your style.css, where they should take effect. Right now those are overwritten with the bb code snippets frmo the plugin, because they are more specific than a global "code" element. In CSS, a specifically named element always has precendence over a "global" declaration.
HTH,
Garvin
Posted: Fri Mar 30, 2007 1:22 am
by TKS
Cool,
That's easy enough...Thanks for the info Garvin!
Posted: Sat Mar 31, 2007 9:38 pm
by TKS
Ok Garvin...just wanted to post this here as successful:
Opened up /plugins/serendipity_event_bbcode/serendipity_event_bbcode.php
Inside I found this:
Code: Select all
.bb-code, .bb-php, .bb-code-title, .bb-php-title {
margin-left: 20px;
margin-right: 20px;
color: black;
direction: ltr;
}
At the bottom of the file.
I added:
And it was fixed. Of course, to future proof this I'd have to add this style to to my template style.css and it would override as Garvin said...but if I change templates I'd have to make edits inside the style.css of the new template and I wasn't about to try and remember that.
So, I changed it inside the event plugin file and now I only have to remember to change it anytime the bbcode plugin is updated.
Thanks again Garvin