December 2017
Beginner
458 pages
7h 52m
English
First, in our photogenik theme folder we will create a new file named single.php:

Next, we will go into the index.php file and copy and paste its code it in the single.php file as shown here:
<?php get_header(); ?><?php if(have_posts()) : ?> <?php while(have_posts()) : the_post(); ?> <?php get_template_part('content', get_post_format()); ?> <?php endwhile; ?><?php else : ?> <?php echo wpautop('Sorry, there are no posts'); ?><?php endif; ?><?php get_footer(); ?>
We will now remove get_template_part in this code:
<?php get_header(); ?><?php if(have_posts()) : ?> <?php while(have_posts()) : the_post(); ?> <?php endwhile; ...
Read now
Unlock full access