Repository navigation
Expand file tree
/
Copy pathclick-load.php
More file actions
76 lines (66 loc) · 1.99 KB
/
Copy pathclick-load.php
File metadata and controls
76 lines (66 loc) · 1.99 KB
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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
<?php
/**
* ClickLoad
*
* Wordpress Plugin providing an additional privacy click requirement
* to load content such as social media streams or single posts
*
* @since 0.1.0
* @package Click_Load
*
* @wordpress-plugin
* Plugin Name: ClickLoad
* Description: Load external content only after an additional privacy click
* Version: 1.0.0
* Requires at least: 5.5
* Requires PHP: 7.3
* Author: Andreas Müller
* Author URI: https://devmount.de
* License: GPL v2+
* License URI: /LICENSE.txt
* Text Domain: click-load
* Domain Path: /languages
*/
// If this file is called directly, abort.
if (!defined('WPINC')) die;
/**
* Current plugin version.
*/
define('CLICK_LOAD_VERSION', '1.0.0');
/**
* The code that runs during plugin activation.
* This action is documented in includes/class-click-load-activator.php
*/
function activate_click_load() {
require_once plugin_dir_path(__FILE__) . 'includes/class-click-load-activator.php';
Click_Load_Activator::activate();
}
/**
* The code that runs during plugin deactivation.
* This action is documented in includes/class-click-load-deactivator.php
*/
function deactivate_click_load() {
require_once plugin_dir_path(__FILE__) . 'includes/class-click-load-deactivator.php';
Click_Load_Deactivator::deactivate();
}
register_activation_hook(__FILE__, 'activate_click_load');
register_deactivation_hook(__FILE__, 'deactivate_click_load');
/**
* The core plugin class that is used to define internationalization,
* admin-specific hooks, and public-facing site hooks.
*/
require plugin_dir_path(__FILE__) . 'includes/class-click-load.php';
/**
* Begins execution of the plugin.
*
* Since everything within the plugin is registered via hooks,
* then kicking off the plugin from this point in the file does
* not affect the page life cycle.
*
* @since 0.1.0
*/
function run_click_load() {
$plugin = new Click_Load();
$plugin->run();
}
run_click_load();