File tree Expand file tree Collapse file tree 1 file changed +25
-0
lines changed Expand file tree Collapse file tree 1 file changed +25
-0
lines changed Original file line number Diff line number Diff line change
1
+ <?php
2
+ /**
3
+ * Plugin Name: The SEO Framework - Force admin display level (Headless Mode)
4
+ * Plugin URI: https://theseoframework.com/
5
+ * Description: Denies TSF's admin display and edit capability to anyone but super admins using Headless Mode.
6
+ * Version: 1.0.0
7
+ * Author: Sybre Waaijer
8
+ * Author URI: https://theseoframework.com/
9
+ * License: GPLv3
10
+ * Requires at least: 5.9
11
+ * Requires PHP: 7.4.0
12
+ * Requires Plugins: autodescription
13
+ *
14
+ * @package My_The_SEO_Framework\AdminDisplayLevel
15
+ */
16
+
17
+ add_action (
18
+ 'plugins_loaded ' ,
19
+ function () {
20
+ if ( is_admin () && ! is_super_admin () )
21
+ defined ( 'THE_SEO_FRAMEWORK_HEADLESS ' )
22
+ or define ( 'THE_SEO_FRAMEWORK_HEADLESS ' , true );
23
+ },
24
+ 0 ,
25
+ );
You can’t perform that action at this time.
0 commit comments