Site logo

Archived topic

How to change the font size and weight of blog titles on archive pages

5 replies · Started by Andrew on June 18, 2021

Viewing posts 1–6 of 6

Hello,

I'm trying to change the font size and weight of blog titles on archive pages. I tried going to Customerizer > Typography > Headings> Archive Content Title (H2), and adjusting it there, but I’m not seeing the changes.

Here’s an example of one of my archive pages: https://prudentreviews.com/category/kitchen-cooking/

I’m trying to make the blog titles font size 19 and weight 400.

I though maybe it was a caching issue, but when I change the H1 on that page, I see the changes right away.

Thanks!
Andrew`

Hi there,

have you added any Custom Functions to your site as your archives are display a H3 element, not the default H2 element.

Yes. I'm seeing this in my content.php file:

<header class="entry-header">
<?php
/**
* generate_before_entry_title hook.
*
* @since 0.1
*/
do_action( 'generate_before_entry_title' );

the_title( sprintf( '<h3 class="entry-title" itemprop="headline">', esc_url( get_permalink() ) ), '</h3>' );

/**
* generate_after_entry_title hook.
*
* @since 0.1
*
* @hooked generate_post_meta - 10
*/
do_action( 'generate_after_entry_title' );
?>
</header><!-- .entry-header -->

Would changing where it says "h3" to "h2" solve the issue?

Yes :)
Is that template in your Child Theme ? As making changes to the parent theme will be lost when theme gets updated.

Yes. It worked, thank you!

Just make sure you are using a child theme if you plan on modifying any of the theme's core files :)

This archived topic is closed to new replies.