• Resolved willgraymagic

    (@willgraymagic)


    Hi Guys

    I had a query that you helped me with about the colour of the FAQ block text which you kindly gave some css code to turn it black from grey. On my FAQ page at the moment all my Q & As are in a classic block and i’d like to put them in a FAQ block for Schema, the question is can i have a different colour for the question to the answer (the Q is in red and the A is in black).

    Cheers
    Will

    The page I need help with: [log in to see the link]

Viewing 7 replies - 1 through 7 (of 7 total)
  • Hi @willgraymagic,

    Thank you for reaching out again.

    Yes, the answers and questions have a different class to them.

    Use the following CSS for changing the question color:

    .wp-block-yoast-faq-block .schema-faq-question{
    color:#yourhexcode;
    }

    Use the following CSS for changing the answer color:

    .wp-block-yoast-faq-block .schema-faq-answer{
    color:#yourhexcode;
    }
    Thread Starter willgraymagic

    (@willgraymagic)

    Hi Jeroen

    Thats great, follow up question could this be different on different pages i.e. just black Q & As on the homepage but then red Qs & black As on the FAQ page or does it have to be the same for every page that uses the FAQ block.

    Cheers
    Will

    Hi @willgraymagic,

    Thanks for your reply.

    You can prefix the CSS selectors with a .page-id-XX where the XX is the page ID number. For example, your FAQ page would be .page-id-42. In order to find your page ID number, go to your Pages overview and hover the title, the URL you then see includes the number.

    Thread Starter willgraymagic

    (@willgraymagic)

    Hi Jeroen

    I’m a bit of a novice with all this, i’m still not sure where to find the page id not sure where pages overview is.

    It is only the FAQ page I would want to do this on so if thats .page-id-42 great, but if you could point me further I would still like to know for future reference.

    How would you put .page-id-42 in with the css code above?

    Cheers
    Will

    Thread Starter willgraymagic

    (@willgraymagic)

    Hi Jeroen

    Since the last message I’ve found the page id’s thank you.

    Just need to know how id add it with the code in the css box would it be

    .page-id-42.wp-block-yoast-faq-block .schema-faq-question{
    color:#yourhexcode;
    }

    For each one.

    Cheers
    Will

    Hi @willgraymagic,

    Thank you for your reply.

    Yes, just add them in front and a space like this:

    .page-id-42 .wp-block-yoast-faq-block .schema-faq-question{
    color:#yourhexcode;
    }

    Hi @willgraymagic,

    We are going ahead and marking this issue as resolved due to inactivity. If you require any further assistance please create a new forum topic. Thank you!

Viewing 7 replies - 1 through 7 (of 7 total)

The topic ‘FAQ block’ is closed to new replies.