• I am currently working on this page on our website:
    https://www.stthomascrookes.org/worshipv2/

    In my ‘Latest Posts’ loop, I want the title, date posted and excerpt to highlight white when you hover (as most of them do). However, most of the posts are under 55 words, but the one post that is over 55 words has a ‘more’ tag and seems to style different.

    How do I:
    a) Get this link to style like the others and
    b) Get rid of the (More…) button on this loop only.

    I think point b) has something to do with the functions but the codex somewhat baffled me!

    Thanks,
    Nick Law

Viewing 3 replies - 1 through 3 (of 3 total)
  • Heh! The church where my parents married in 1942 and where I was baptised in 1947!

    If I understand you correctly, you’re talking about the fact that the text doesn’t go white when you hover over a truncated excerpt (one with a ‘More’ link).

    I think you need a style rule for:

    div.article_excerpt p a:hover {
        color: #FFF;
    }

    If that doesn’t work you probably need to just keep on making it more and more specific until it gets enough points to over-ride any similar rule. And you’ll probably need to do it in your second style sheet to ensure it’s read late in the cascade.

    You could even do it in the style sheet of a child theme, if you’re not using a child theme already. Which I hope you are, by the way.

    HTH

    PAE

    Thread Starter nicklawmusic

    (@nicklawmusic)

    Thanks for that. It hasn’t worked, but I’ll keep pressing on. What a coincidence about St Thomas’! The CSS I am using is a child theme, yes.

    Try making the rule more specific by walking back up the tree. I don’t suggest you go as mad as this (although you could), but you could take a selection from this:

    div#content
    div#latest_posts_wrapper
    div.article_loop_wrapper
    div.article_excerpt_link_wrap
    div.article_exerpt
    p
    a:hover
    {
       ...
    }

    In fact you could walk all the way back to the body tag if you wanted, but something before then should work.

    Cheers

    PAE

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘CSS the_excerpt styling problem’ is closed to new replies.