How do I add the category names on the featured image of the posts?

Hi,

I was hoping you could help me add the category names associated with each post on top of the featured images for each post instead of as a list below each featured image?

Thanks in advance!

Website: http://ccdatahub.ipsl.fr/

Hello there,

There’s no an instant way to accomplish it. The solution would be extra coding with a child theme. As it’s a complex task and goes beyond our support policy, this prevents me to go further. I’d encourage you to hire a freelancer.

Thank you for your understanding.

Regards,
Kharis

Thanks Kharis, Sure I understand. I have already established a child theme and have started adding code to the style.css, functions.php and header and footer scripts. Maybe I could tackle what I need another way that should be more straightforward. How about if I remove the Date and Category icons below the featured image leaving only the category icons? And, if possible increase the font size of the category labels so that they are emphasised? I would like that the categories are used as one of the primary means of navigating through the data posts on the website. Would that be something that is within your support policy? Cheers

I’ve tweaked the code to remove the category widget and date from below the featured images by modifying the script posted in Change post meta on blog page and single posts

But, I would still like to be able to see this information when viewing the details of a single post. I assume there are various ways to do this?

Avoid editing the sydney_posted_on(). Then in your site’s customizer, uncheck the options that says “Hide post meta on singles?”. Add this CSS code to Appearance > Customize > Additional CSS from dashboard.

    .posted-on {
      display: none;
    }

    .single-meta .posted-on {
      display: inline;
    }

Regards,
Kharis

Thanks Kharis,
I am trying to keep all additional css code in the style.css of the Sydney Pro child theme that I created and avoid using “Appearance-> Csutomize>Additional CSS” . Could you send the code I should add to my child themes style.css file to get the same result? That would be great!

Hello there,

That code can be put into child theme’s stylesheet as well. That should not produce any difference.

Regards,
Kharis