single.php 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. <?php
  2. /**
  3. * The template for displaying all single posts
  4. *
  5. * @link https://developer.wordpress.org/themes/basics/template-hierarchy/#single-post
  6. *
  7. * @package spice-software
  8. */
  9. get_header();?>
  10. <section class="section-space blog">
  11. <div class="container<?php echo esc_html(spice_software_single_post_container());?>">
  12. <div class="row">
  13. <div class="col-lg-8 col-md-7 col-sm-12 standard-view blog-single">
  14. <?php
  15. while (have_posts()): the_post();
  16. if ( ! function_exists( 'spice_software_plus_activate' ) ){
  17. get_template_part('template-parts/content', 'single');
  18. }
  19. else{
  20. include(SPICE_SOFTWAREP_PLUGIN_DIR.'/inc/template-parts/content-single.php');
  21. }
  22. endwhile;
  23. if(function_exists( 'spice_software_plus_activate' )):
  24. if(get_theme_mod('spice_software_enable_related_post',true ) ===true ):
  25. include(SPICE_SOFTWAREP_PLUGIN_DIR.'/inc/template-parts/related-posts.php');
  26. endif;
  27. endif;
  28. if (get_theme_mod('spice_software_enable_single_post_admin_details', true) === true):
  29. get_template_part('template-parts/auth-details');
  30. endif;
  31. // If comments are open or we have at least one comment, load up the comment template.
  32. if (comments_open() || get_comments_number()) : comments_template();
  33. endif;
  34. ?>
  35. </div>
  36. <div class="col-lg-4 col-md-5 col-sm-12">
  37. <div class="sidebar s-l-space">
  38. <?php dynamic_sidebar('sidebar-1'); ?>
  39. </div>
  40. </div>
  41. </div>
  42. </div>
  43. </section>
  44. <?php get_footer(); ?>