Customizr Slider: How to change size from h1 to h2? (6 posts)

  1. Ypanesa
    Posted 2 years ago #

    I am using a customizr child theme. Now I would like to change the title size h1 to h2. I know how to define h1 or h2 with css. I want to change h1 to h2. Because Google doesn't like more than one h1 on a page.

    Would it be possible to have h1 in the main slider image and h2 for the rest?

  2. kaniamea
    Posted 2 years ago #

    I think you can only change titles on all slides, so they are all h2. You can do it in your child parts/class-content-slider.php file by modifying line 215 from apply_filters( 'tc_slide_title_tag', 'h1' ) to apply_filters( 'tc_slide_title_tag', 'h2' )

  3. Ypanesa
    Posted 2 years ago #

    Thank you so much. It works (of course ;)).

  4. Deetech
    Posted 2 years ago #

    Hi, I want to change slider H1 to H2 but cannot find parts/class-content-slider.php. I see a file in parts/class-header-slider.php but it doesnt have the said code.

    Oh.. I got it. Had to changed <h1 <?php echo $color_style ?>><?php echo $title ?></h1> to <h2 <?php echo $color_style ?>><?php echo $title ?></h2>

  5. Ypanesa
    Posted 2 years ago #

    It is on line 430 in the parts/class-content-slider.php file.

    ( $data['title'] != null ) ? sprintf('<%1$s %2$s>%3$s</%1$s>',
    apply_filters( 'tc_slide_title_tag', 'h2' ),
    ) : '',
  6. ElectricFeet
    Posted 2 years ago #

    Multiple h1s are OK. See here.

Topic Closed

This topic has been closed to new replies.

About this Theme

About this Topic