Display Featured Image in index.php
-
I’m trying to create my own theme (based on standards of WP).
Many things are right, but the home page list that I want no ! I change the default list of site, to show
thumb
title
post data
categoryThe Thumb option, based in Featured Image dont work. If I use has_thumbmail always receive FALSE (yes, I edit some post and choose an image was Feature Image por post).
I saw the documentation about it, and change but nothing. Links that I used:
https://codex.www.ads-software.com/Function_Reference/add_theme_support
https://www.sitepoint.com/how-to-add-featured-image-thumbnails-to-your-wordpress-theme/The code from template.php
<?php if ( 'post' == get_post_type() ) : ?> <div class="entry-meta"> <?php echo('Has Thumbnail: ' . has_post_thumbnail()); if ( has_post_thumbnail() ) { the_post_thumbnail(); } ?> <?php twentyeleven_posted_on(); ?> </div><!-- .entry-meta --> <?php endif; ?>
[Moderator Note: Please post code & markup between backticks or use the code button. Your posted code may now have been permanently damaged by the forum’s parser.]
Some idea ???
- The topic ‘Display Featured Image in index.php’ is closed to new replies.