the title is fairly self-explanatory.
I click on one of the products and URL is properly changing to /product/product-1/ but the content is still index.php instead of single.php.
so this is the index.php :
<?php get_header(); ?>
<?php View::render('partials/top-bar'); ?>
<?php View::render('partials/header'); ?>
<?php View::render('partials/content'); ?>
<?php get_footer(); ?>
the partial/content is pretty big but this is the logic part of it which has the WordPress loop
<?php
$new_products = new WP_Query( array(
'post_type' => 'product',
'order' => 'ASC',
'orderby' => 'meta_value_num',
'meta_key' => Product::PRICE_META_KEY,
) );
?>
<?php if ( $new_products->have_posts() ): ?>
<?php while ( $new_products->have_posts() ): $new_products->the_post(); ?>
<div class="spost clearfix">
<div class="entry-image">
<a href="<?php echo get_the_permalink(); ?>"><img
src="<?php echo Asset::image( 'shop/small/1.jpg' ); ?>" alt="Image"></a>
</div>
<div class="entry-c">
<div class="entry-title">
<h4>
<a href="<?php echo get_the_permalink(); ?>"><?php echo get_the_title(); ?></a>
</h4>
</div>
<ul class="entry-meta">
<li class="color"><?php echo Product::price( get_the_ID() ); ?></li>
<li><i class="icon-star3"></i> <i class="icon-star3"></i> <i
class="icon-star3"></i> <i class="icon-star3"></i> <i
class="icon-star-half-full"></i></li>
</ul>
</div>
</div>
<?php endwhile; ?>
<?php else: ?>
<?php endif; ?>
</div>
single.php has some content but the problem doesn't seem to be related to that, so I didn't include the code here.
Thank you in advance.
</div>