+1 vote
in Web & Google by (11k points)
I am using the free version of WPtouch on my website. By default, it shows the featured image in the background of the title of all posts. As my posts already have images, I do not want to show the same image in the header. I did not find any option in the settings of Wptouch. How can I remove the featured image from the header background?

1 Answer

0 votes
by (15.1k points)

You need to make some changes in the php code "single.php" which can be found in the following folder: wp-content/plugins/wptouch/themes/bauhaus/default/single.php

Open single.php in any editor and search for the line "the_post_thumbnail('large', array( 'class' => 'post-thumbnail wp-post-image' ) ); ?>"

This code is responsibe to show the featured image as the header background. Just comment out this code to remove the image.

Replace

<?php the_post_thumbnail('large', array( 'class' => 'post-thumbnail wp-post-image' ) ); ?>

with

<?php // DO NOT SHOW THE FEATURED IMAGE IN TITLE the_post_thumbnail('large', array( 'class' => 'post-thumbnail wp-post-image' ) ); ?>

...