buttons to proper category archive

This commit is contained in:
jorge 2022-04-29 10:43:05 +02:00
parent 8df15bd96a
commit 0ed0c0c59b
3 changed files with 18 additions and 18 deletions

View File

@ -76,8 +76,8 @@
<aside>
<?php //get_template_part( 'template-parts/navigation', 'prevnext' ); ?>
<nav>
<div class="post-previous"><?php previous_posts_link( __( 'Newer posts &rarr;', 'foundationpress' ) ); ?></div>
<div class="post-next"><?php next_posts_link( __( '&larr; Older posts', 'foundationpress' ) ); ?></div>
<div class="post-next"><?php next_posts_link( __( '&larr; Older', 'foundationpress' ) ); ?></div>
<div class="post-previous"><?php previous_posts_link( __( 'Newer &rarr;', 'foundationpress' ) ); ?></div>
<?php
// button load more simple
// echo '<a class="button hollow" href="' . esc_url( get_category_link( get_cat_ID($thiscategory) ) ) . '">';

View File

@ -67,8 +67,8 @@
</main>
<aside>
<nav>
<div class="post-previous"><?php previous_posts_link( __( 'Newer posts &rarr;', 'foundationpress' ) ); ?></div>
<div class="post-next"><?php next_posts_link( __( '&larr; Older posts', 'foundationpress' ) ); ?></div>
<div class="post-next"><?php next_posts_link( __( '&larr; Older', 'foundationpress' ) ); ?></div>
<div class="post-previous"><?php previous_posts_link( __( 'Newer &rarr;', 'foundationpress' ) ); ?></div>
</nav>
</aside>
</section>

View File

@ -67,22 +67,22 @@
</article>
<?php endwhile;//end of the loop ?>
</main>
<?php wp_reset_postdata(); ?>
<?php else : //if no post in query ?>
<aside>
<?php //get_template_part( 'template-parts/navigation', 'prevnext' ); ?>
<nav>
<?php
// button load more simple
echo '<a class="button hollow" href="' . esc_url( get_site_url( null, $thiscategory ) ) . '">';
echo 'load more ' ;
echo $thiscategory;
echo '</a>';
?>
</nav>
</aside>
<?php wp_reset_postdata(); ?>
<?php else : //if no post in query ?>
<p><?php _e( 'Sorry, no posts matched your criteria.' ); ?></p>
</main>
<?php endif; ?>
<aside>
<?php //get_template_part( 'template-parts/navigation', 'prevnext' ); ?>
<nav>
<?php
// button load more simple
echo '<a class="button hollow" href="' . esc_url( get_category_link( get_cat_ID($thiscategory) ) ) . '">';
echo 'load more ' ;
echo $thiscategory;
echo '</a>';
?>
</nav>
</aside>
</section>