Styling your blog posts
First add an image to the hello world blog post. Edit the blog post in the WordPress Dashboard and add a Featured Image, as shown in the following screenshot:
Note
Make sure that your WordPress installation has a writable wp-content/uploads
directory to store the uploaded media. Also see https://codex.wordpress.org/Changing_File_Permissions for more information about file permissions.
Now edit the loop-archive.php
file so that the HTML and PHP code looks like that shown here:
<article id="post-<?php the_ID(); ?>" <?php post_class(''); ?> role="article"> <?php the_post_thumbnail('full'); ?> <div class="blog-post"> <header class="article-header"> <h2><a href="<?php the_permalink() ?>" rel="bookmark" ><?php the_title(); ?></a></h2> <?php get_template_part( 'parts/content', 'byline' ); ?> </header> <!-- end article header -->...