skip to Main Content

Need to change my WordPress title headings from h5 to h2. Nothing seems to work.

<div class="box-text spacing-medium text-center">
    <h5  uppercase"><?php the_title(); ?></h5>
            <?php the_title( '<h2 class="post-title">', '</h2>' ); ?>

I tried changing h5 to h2 and it didn’t fix anything

2

Answers


  1. <div class="box-text spacing-medium text-center">
    <h2 uppercase"><?php the_title(); ?></h2>
    <?php the_title( '<h2 class="post-title">', '</h2>' ); ?>
    
    Login or Signup to reply.
  2. I have made a minor change in the code and it is working fine, please find the updated code.

    <div class="box-text spacing-medium text-center">
        <h5  class="uppercase">
         <?php the_title(); ?>
        </h5>
        <?php the_title( '<h2 class="post-title">', '</h2>' ); ?>
     </div>
    

    Source Code Screenshot

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search