Checker.php
1 year ago
PostContent.php
9 months ago
Redirect.php
1 year ago
RestrictionShortcode.php
3 months ago
SearchAndAPI.php
1 year ago
index.php
5 years ago
restricted-template.php
1 year ago
restricted-template.php
35 lines
| 1 | <?php |
| 2 | /** |
| 3 | * The template for displaying restricted pages. |
| 4 | * |
| 5 | * @package ProfilePress |
| 6 | */ |
| 7 | |
| 8 | if ( ! defined('ABSPATH')) { |
| 9 | exit; // Exit if accessed directly. |
| 10 | } |
| 11 | |
| 12 | /** @global array $args */ |
| 13 | |
| 14 | $content = $args['noaccess_action_message_custom'] ?? ''; |
| 15 | |
| 16 | if (empty($content)) { |
| 17 | |
| 18 | $content = ppress_settings_by_key( |
| 19 | 'global_restricted_access_message', |
| 20 | esc_html__('You are unauthorized to view this page.', 'wp-user-avatar'), |
| 21 | true |
| 22 | ); |
| 23 | } |
| 24 | |
| 25 | get_header(); |
| 26 | |
| 27 | ?> |
| 28 | <main id="site-content" class="ppress-main-container"> |
| 29 | <div class="ppress-container-div"> |
| 30 | <?php echo do_shortcode(wp_kses_post($content)); ?> |
| 31 | </div> |
| 32 | </main> |
| 33 | |
| 34 | <?php get_footer(); ?> |
| 35 |