Advertisement
Guest User

Untitled

a guest
Aug 21st, 2019
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.66 KB | None | 0 0
  1. <?php
  2. /**
  3. * The Template for displaying all single products
  4. *
  5. * This template can be overridden by copying it to yourtheme/woocommerce/single-product.php.
  6. *
  7. * HOWEVER, on occasion WooCommerce will need to update template files and you
  8. * (the theme developer) will need to copy the new files to your theme to
  9. * maintain compatibility. We try to do this as little as possible, but it does
  10. * happen. When this occurs the version of the template file will be bumped and
  11. * the readme will list any important changes.
  12. *
  13. * @see https://docs.woocommerce.com/document/template-structure/
  14. * @package WooCommerce/Templates
  15. * @version 1.6.4
  16. */
  17.  
  18. if ( ! defined( 'ABSPATH' ) ) {
  19. exit; // Exit if accessed directly
  20. }
  21.  
  22. get_header( 'shop' ); ?>
  23.  
  24. <?php
  25. /**
  26. * woocommerce_before_main_content hook.
  27. *
  28. * @hooked woocommerce_output_content_wrapper - 10 (outputs opening divs for the content)
  29. * @hooked woocommerce_breadcrumb - 20
  30. */
  31. do_action( 'woocommerce_before_main_content' );
  32. ?>
  33.  
  34. <?php while ( have_posts() ) : the_post(); ?>
  35.  
  36. <?php wc_get_template_part( 'content', 'single-product' ); ?>
  37.  
  38. <?php endwhile; // end of the loop. ?>
  39.  
  40. <?php
  41. /**
  42. * woocommerce_after_main_content hook.
  43. *
  44. * @hooked woocommerce_output_content_wrapper_end - 10 (outputs closing divs for the content)
  45. */
  46. do_action( 'woocommerce_after_main_content' );
  47. ?>
  48.  
  49. <?php
  50. /**
  51. * woocommerce_sidebar hook.
  52. *
  53. * @hooked woocommerce_get_sidebar - 10
  54. */
  55. do_action( 'woocommerce_sidebar' );
  56. ?>
  57.  
  58. <?php get_footer( 'shop' );
  59.  
  60. /* Omit closing PHP tag at the end of PHP files to avoid "headers already sent" issues. */
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement