Search code examples
phpwordpresstags

How to change wordpress theme categories title tag (entry.title) from <h1> to <h2>


this is the webpage same thing happens for vgo 2023.

so I have multiple h1 titles on the same page

see image: see image

what do I need to change and the h1 tags into h2 tags?

to the answer bellow image: this is how my content.php looks like

code for content.php:

<?php
/**
 * @package electro
 */

$additional_post_classes = apply_filters( 'electro_additional_post_classes', array('') );

?>

<article id="post-<?php the_ID(); ?>" <?php post_class( $additional_post_classes ); ?>>

    <?php
    /**
     * @hooked electro_post_header() - 10
     * @hooked electro_post_meta() - 20
     * @hooked electro_post_content() - 30
     */
    do_action( 'electro_loop_post' );
    ?>

</article><!-- #post-## -->

can anybody help out with this ?


Solution

  • Check your theme function, see file content.php in the template-parts folder, and change tag h1 to h2 as needed. See attachment. enter image description here