PluginProbe
User Profile Builder – Beautiful User Registration Forms, User Profiles & User Role Editor / 3.16.5
User Profile Builder – Beautiful User Registration Forms, User Profiles & User Role Editor v3.16.5
4.0.3 4.0.2 4.0.1 4.0.0 3.16.6 3.16.5 3.16.4 3.16.3 3.16.2 3.16.1 3.16.0 3.15.9 3.9.9 3.9.5 3.9.6 3.9.7 3.9.8 1.1.7 1.1.8 1.1.9 2.0.2 2.0.3 2.0.4 2.0.5 2.0.6 All 341 releases
profile-builder / features / content-restriction / templates / archive-product.php

archive-product.php in User Profile Builder – Beautiful User Registration Forms, User Profiles & User Role Editor 3.16.5, at features/content-restriction/templates/archive-product.php

68 lines 1.7 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * Template used to overwrite the main shop page which is a post type archive
4 */
5
6 if ( ! defined( 'ABSPATH' ) ) {
7 exit; // Exit if accessed directly
8 }
9
10 get_header( 'shop' ); ?>
11
12 <?php
13 /**
14 * woocommerce_before_main_content hook.
15 *
16 * @hooked woocommerce_output_content_wrapper - 10 (outputs opening divs for the content)
17 * @hooked woocommerce_breadcrumb - 20
18 */
19 do_action( 'woocommerce_before_main_content' );
20 ?>
21
22 <?php if ( apply_filters( 'woocommerce_show_page_title', true ) ) : ?>
23
24 <h1 class="page-title"><?php woocommerce_page_title(); ?></h1>
25
26 <?php endif; ?>
27
28 <?php
29 /**
30 * Display restriction message
31 *
32 */
33
34 $post_id = wc_get_page_id( 'shop' );
35
36 if ($post_id != -1) {
37 $shop_post = get_post( $post_id );
38 if( is_user_logged_in() ) {
39 $message = wppb_content_restriction_process_content_message( 'logged_in', get_current_user_id(), $post_id );
40 echo do_shortcode( apply_filters( 'wppb_content_restriction_message_logged_in', $message, $shop_post->post_content, $shop_post, get_current_user_id() ) );
41 }
42 else{
43 $message = wppb_content_restriction_process_content_message( 'logged_out', get_current_user_id(), $post_id );
44 echo do_shortcode( apply_filters( 'wppb_content_restriction_message_logged_out', $message, $shop_post->post_content, $shop_post, get_current_user_id() ) );
45 }
46 }
47 ?>
48
49 <?php
50 /**
51 * woocommerce_after_main_content hook.
52 *
53 * @hooked woocommerce_output_content_wrapper_end - 10 (outputs closing divs for the content)
54 */
55 do_action( 'woocommerce_after_main_content' );
56 ?>
57
58 <?php
59 /**
60 * woocommerce_sidebar hook.
61 *
62 * @hooked woocommerce_get_sidebar - 10
63 */
64 do_action( 'woocommerce_sidebar' );
65 ?>
66
67 <?php get_footer( 'shop' ); ?>
68