Some CSS help
-
Hello, some few CSS questions from a noob, need to know which code to add to custom css for:
1) how to edit footer background color.
2) change widget title text color and widget background color
3) change main content text colorThnx
-
Can you post a link to your site?
Points 1-3 are ok.
Just need to know, if possibile, how to edit widget areas background colors.
I did some changes via Custom CSS, but didn’t work. I edited style.css manually and changes took effect. Why?
my website
You’ve got a syntax error in your custom CSS. On line 14 you have:
widget-title { color: #004552;}but it should be
.widget-title { color: #004552;}Note the period before
widget-title.To clarify, when you refer to the widget area background color, you’re referring to the area labeled “In Evidenza”, correct? If so, use this code in your custom CSS plugin:
#secondary { background: #00ff00; }OK thnaks a lot!!!
And to have widget area text in white?
Thnx
Sorry, i meant link (not visited) color.
For text color i added : color: #FFFFFF;
You’ve got another syntax error in your custom CSS. On line 16, you’ve got:
/* #secondary { background: #527c84; color: #FFFFFF;}but that /* at the beginning means it’s a comment, which the browser ignores. So it should look like this:
#secondary { background: #527c84; color: #FFFFFF;}To change the color of the links in the sidebar, use this code:
#secondary a { color: #00ff00; } #secondary li a { color: #00ff00; }yeah i commented those lines because i need to wait for my client to decide the colors.
THnx a lor for advices.
One last question:
i’ve translated the template with Poedit.
But the search widget still displays “search” label inside, instead the italian translated word “cerca”.
Any suggestions?
Looks like a problem with the theme. The string that acts as the placeholder (“Search …”) isn’t actually in the theme’s POT file. It would be best if the theme author fixed this in a future update, but for now, you could fix it yourself in a child theme.
You’d have to copy the POT file from the parent theme to
themes/bota-child/languagesand then edit the catalog to load the appropriate strings. In PoEdit, under Catalog > Properties > Sources paths, you’d have to change “Base path” from.to../../bota/languages, and then under Sources keywords, you’d have to addesc_attr_eto “Additional keywords”. Once that’s done, you should see the new string in the catalog, ready for translation. You’d then have to load the catalog into your child theme usingload_theme_textdomain():function load_translations() { load_theme_textdomain( 'bota', get_stylesheet_directory() . '/languages' ); } add_action( 'after_setup_theme', 'load_translations' );Thnx for the great help man!
I have one more problem:
if i change the link color, even links in the side bar will change.
How to control them separate?thnx
I’ve added to custom css:
#secondary a { color: #FFFFFF; } #secondary li a { color: #FFFFFF; } #secondary a:visited { color: #FFFFFF;}but it still takes the styles from #main
what’s wrong?
From what I can see, you don’t have any links in your sidebar that would use those CSS rules. The links in the section labeled “Risorse” (“Bandi e Concorsi”, “Formazione”, etc.) are controlled by the rule
#dc_jqaccordion_widget-2-item ul a:hover { ... }. Are those the links you’re trying to change?I had a scrolling news widget, the title of the news had a link, and it was red like main content link color.
I disabled it for the moment due to that color.
If you go in the Contatti widget and click in the mail one, the mailto on the mail address itself it’s stil red!Help!
What’s happening is that
#secondary a { color: #FFFFFF; } #secondary li a { color: #FFFFFF; } #secondary a:visited { color: #FFFFFF;}and
#main a { color: #c82412; } #main li a { color: #c82412; } #main a:visited { color: #c82412;}have the same specificity and since the rules beginning with
#mainare defined last, the browser uses those rules. Your best bet is to move the rules beginning with#secondaryafter the rules beginning with#main. That way, the links in the main content area will remain red, but the mailto link in the sidebar will be white (or whatever color your client chooses).
The topic ‘Some CSS help’ is closed to new replies.
