I am new to Drupal and I am attempting to change the background color of the blocks on my frontpage. I have three in each sidebar and would like to add some color to give it some contrast. I have looked through all the .css files and used firebug, but having a difficult time finding where it needs to be changed. Thanks in advance.

Comments

cubbase’s picture

Maybe it is an overcomplicated solution, but when I want to change some colors I just printscreen the website; then, with the color picker of photoshop, I select the color (be sure to use firefox as it doesn't change the rendered colors) the hexadecimal value is then on the bottom of the color picker dialog box.

(you can just, in photoshop, click with the picker on an empty document then drag your color picker (still clicked) into your website browser and release it on the color you want to pick)

I use it in the windows explorer to search every occurence of the hex value ( don't forget to includethe content of files ) in my css folder - or replace it at the same time with a good text editor that can replace into multiple documents at once.

komal.savla’s picture

Hi,
If you want the same background color for all the blocks in first sidebar then the following is the sample css that you can add in your block.css file

#sidebar-first .block {
  background: #EEEEEE;
  float: left;
  width: 232px;
}

In the same way you can do for the blocks in the sidebar-second.

Thanks,
Komal

amwlkaw’s picture

Thanks. That was helpful in understanding what was going on with the CSS. However, it didn't do anything to the blocks. I will have to dig further to see why this is true.

hankinstrio’s picture

#2's idea worked for me. I'm using D7 Marinelli 3x and now I have a deep blue side bar block with a list of white words I'd like to link to pages. I am noob and I need to change the appearance of the links in this block. I want them to stay white and then change to the light blue underline when I hover over them. Can I do that and still maintain the normal link appearance in the main region which is still all white?

hankinstrio’s picture

Oops, I am at #4 below :)

nhhanh’s picture

hi komal.savla! thank so much :)

BhumikaVarshney’s picture

Issue summary: View changes
Status: Active » Needs review

Hi,
If you want to change the block's background color of a particular region, sample code css is given below for the sidebar region blocks:
#sidebar-first .block {
background: #EEEEEE;
}
Same you can use the code for other regions also, you just need to change the region name.