-
Notifications
You must be signed in to change notification settings - Fork 10
/
block-visibility.php
44 lines (39 loc) · 1.46 KB
/
block-visibility.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
<?php
/**
* Plugin Name: Block Visibility
* Plugin URI: https://www.blockvisibilitywp.com/
* Description: Provides visibility controls and scheduling functionality to all WordPress blocks.
* Version: 3.7.0
* Requires at least: 6.5
* Requires PHP: 7.4
* Author: Nick Diego
* Author URI: https://www.nickdiego.com
* License: GPL-2.0-or-later
* License URI: https://www.gnu.org/licenses/gpl-2.0.html
* Text Domain: block-visibility
* Domain Path: /languages
*
* @package block-visibility
*/
namespace BlockVisibility;
defined( 'ABSPATH' ) || exit;
define( 'BLOCK_VISIBILITY_VERSION', '3.7.0' );
define( 'BLOCK_VISIBILITY_PLUGIN_FILE', __FILE__ );
define( 'BLOCK_VISIBILITY_ABSPATH', dirname( BLOCK_VISIBILITY_PLUGIN_FILE ) . '/' );
define( 'BLOCK_VISIBILITY_PLUGIN_URL', plugin_dir_url( BLOCK_VISIBILITY_PLUGIN_FILE ) );
define( 'BLOCK_VISIBILITY_PLUGIN_BASENAME', plugin_basename( BLOCK_VISIBILITY_PLUGIN_FILE ) );
define( 'BLOCK_VISIBILITY_SETTINGS_URL', admin_url( 'options-general.php?page=block-visibility-settings' ) );
// Include the main Block_Visibility class.
require_once BLOCK_VISIBILITY_ABSPATH . 'includes/class-block-visibility.php';
/**
* Initialize the Block Visibility plugin.
*
* @since 3.6.0
*
* @return void
*/
function init() {
$plugin = new \Block_Visibility();
$plugin->init();
}
add_action( 'plugins_loaded', __NAMESPACE__ . '\init' );