• Resolved menaabebe

    (@menaabebe)


    I am using the MYgRID2 1.3 theme, and having a hard time changing the background color on the home page…and all the other pages.

    I looked at some forum posts and a youtube video, but they didn’t work for me. I would really appreciate some help…I’ve been at it for some hours now.

    Thank you.

Viewing 10 replies - 1 through 10 (of 10 total)
  • does the theme use body_class()?
    https://codex.www.ads-software.com/Function_Reference/body_class

    then you could base your styles on the css classes output by this function.
    if not, it will be more difficult to have different background colors.

    if you post a link to your site, someone might be able to make some suggestions.

    Thread Starter menaabebe

    (@menaabebe)

    hey alchymyth, thanks for your response. I don’t think the theme uses body_class() b/c I tried that technique, and it didn’t work.

    here is the link to my site:

    https://djdowjones.us

    Which is the color you want to change? I’m guessing it’s the DJ Dow Jones background color. If that’s the case, you can change it going to you style.css file and finding this on line 62:

    body {
    margin:0;
    padding:0;
    font-family:Arial, sans-serif;
    color:#333;
    background:#eee;
    font-size:9pt;
    line-height:20pt;
    text-shadow:0 2px 3px #fff;
    }

    Change de background:#eee to the color you want to use, and that’s it ??

    Thread Starter menaabebe

    (@menaabebe)

    Hey Rodni, I followed your suggestion, and it worked…but the home page was the only background color I wanted to change. Now all my pages have a white background…do you know how I can change only the home page?

    your theme does use the body_class() – therefore you have a specific css class .home on the home page to use in style.css:

    add this line:

    body.home { background: #fff; }

    Thread Starter menaabebe

    (@menaabebe)

    Alchymyth, I tried that and it didn’t work for me. Any specific place I should be placing the code or is there a step I missing?

    I appreciate all the help.

    just after the other body style (the one that @rodni posted) should be fine;
    however, i can’t find the new style in your stylesheet – have you removed it after the change or did you edit the wrong file?

    if you can’t see changes to the stylesheet immediately in your browser, try to press ‘CTRL F5’ to clear the browser cache.

    Thread Starter menaabebe

    (@menaabebe)

    ohhh yes, thank you very much alchymyth…it worked.

    If you have the time, I have another question. Right now, when you scroll the mouse over the “DJ Dow Jones” logo on the home page, the image fades. Is there a way I can stop that? I’ve been scouring google for an answer.

    the fading looks like some javascript or jQuery effect, possibly intended by the theme author – but that is not my area of expertise…

    Thread Starter menaabebe

    (@menaabebe)

    well, I appreciate all your help. Have a great weekend.

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘Change background color on home page’ is closed to new replies.