PluginProbe ʕ •ᴥ•ʔ
Strong Testimonials / 2.36
Strong Testimonials v2.36
3.3.1 trunk 1.0.1 2.30.9 2.31.10 2.32 2.32.1 2.32.2 2.32.3 2.32.4 2.33 2.34 2.35 2.36 2.37 2.38 2.38.1 2.39 2.39.1 2.39.2 2.39.3 2.40.0 2.40.1 2.40.2 2.40.3 2.40.4 2.40.5 2.40.6 2.40.7 2.41.0 2.41.1 2.50.0 2.50.1 2.50.2 2.50.3 2.50.4 2.51.0 2.51.1 2.51.2 2.51.3 2.51.4 2.51.5 2.51.6 2.51.7 2.51.8 2.51.9 3.0.0 3.0.1 3.0.2 3.0.3 3.1.0 3.1.1 3.1.10 3.1.11 3.1.12 3.1.13 3.1.14 3.1.15 3.1.16 3.1.17 3.1.18 3.1.19 3.1.2 3.1.20 3.1.3 3.1.4 3.1.5 3.1.6 3.1.7 3.1.8 3.1.9 3.2.0 3.2.1 3.2.10 3.2.11 3.2.12 3.2.13 3.2.14 3.2.15 3.2.16 3.2.17 3.2.18 3.2.19 3.2.2 3.2.20 3.2.21 3.2.22 3.2.3 3.2.4 3.2.5 3.2.6 3.2.7 3.2.8 3.2.9 3.3.0
strong-testimonials / admin / compat.php
strong-testimonials / admin Last commit date
about 7 years ago css 7 years ago img 7 years ago js 7 years ago menu 7 years ago partials 7 years ago scss 7 years ago settings 7 years ago admin-notices.php 7 years ago admin.php 7 years ago class-strong-testimonials-admin-category-list.php 7 years ago class-strong-testimonials-admin-list.php 7 years ago class-strong-testimonials-admin-scripts.php 7 years ago class-strong-testimonials-defaults.php 7 years ago class-strong-testimonials-help.php 7 years ago class-strong-testimonials-list-table.php 7 years ago class-strong-testimonials-page-shortcodes.php 7 years ago class-strong-testimonials-post-editor.php 7 years ago class-strong-testimonials-updater.php 7 years ago class-strong-views-list-table.php 7 years ago class-walker-strong-category-checklist.php 7 years ago class-walker-strong-form-category-checklist.php 7 years ago compat.php 7 years ago custom-fields-ajax.php 7 years ago custom-fields.php 7 years ago form-preview.php 7 years ago view-list-order.php 7 years ago views-ajax.php 7 years ago views-validate.php 7 years ago views.php 7 years ago
compat.php
117 lines
1 <?php
2
3 /**
4 * Prevent other post ordering plugins, in admin_menu hook.
5 *
6 * @since 1.16.0
7 */
8 function wpmtst_deny_plugins_menu() {
9
10 /**
11 * Post Types Order
12 */
13 if ( is_plugin_active( 'post-types-order/post-types-order.php' ) ) {
14 remove_submenu_page( 'edit.php?post_type=wpm-testimonial', 'order-post-types-wpm-testimonial' );
15 }
16
17 }
18 add_action( 'admin_menu', 'wpmtst_deny_plugins_menu', 200 );
19
20
21 /**
22 * Plugin and theme compatibility in admin.
23 *
24 * @since 2.4.0
25 */
26 function wpmtst_compat_admin_init() {
27 $theme = wp_get_theme();
28
29 /* ------------------------------------------------------------
30 * Theme Name: Mercury
31 * Theme URI: http://themes.themegoods2.com/mercury
32 * Description: Premium Template for Photography Portfolio
33 * Version: 1.7.5
34 * Author: Peerapong Pulpipatnan
35 * Author URI: http://themeforest.net/user/peerapong
36 * ------------------------------------------------------------
37 * Mercury enqueues its scripts and styles poorly.
38 * 1. on the `admin_init` hook
39 * 2. UNconditionally
40 */
41 if ( 'Mercury' == $theme->get( 'Name' ) && 'http://themes.themegoods2.com/mercury' == $theme->get( 'ThemeURI' ) ) {
42
43 /** Screen information is not available yet. */
44 //$screen = get_current_screen();
45 //if ( $screen && 'wpm-testimonial' == $screen->post_type ) {
46
47 if ( false !== strpos( $_SERVER['QUERY_STRING'], 'post_type=wpm-testimonial' ) ) {
48 if ( function_exists( 'pp_add_init' ) ) {
49 remove_action( 'admin_init', 'pp_add_init' );
50 }
51 }
52
53 }
54 }
55 add_action( 'admin_init', 'wpmtst_compat_admin_init', 1 );
56
57
58 /**
59 * Prevent other post ordering plugins, in admin_init hook.
60 *
61 * @since 1.16.0
62 */
63 function wpmtst_deny_plugins_init() {
64
65 /**
66 * Intuitive Custom Post Order
67 */
68 if ( is_plugin_active( 'intuitive-custom-post-order/intuitive-custom-post-order.php' ) ) {
69 $options = get_option( 'hicpo_options' );
70 $update = false;
71
72 if ( isset( $options['objects'] ) && is_array( $options['objects'] ) ) {
73 if ( in_array( 'wpm-testimonial', $options['objects'] ) ) {
74 $options['objects'] = array_diff( $options['objects'], array( 'wpm-testimonial' ) );
75 $update = true;
76 }
77 }
78
79 if ( isset( $options['tags'] ) && is_array( $options['tags'] ) ) {
80 if ( in_array( 'wpm-testimonial-category', $options['tags'] ) ) {
81 $options['tags'] = array_diff( $options['tags'], array( 'wpm-testimonial-category' ) );
82 $update = true;
83 }
84 }
85
86 if ( $update )
87 update_option( 'hicpo_options', $options );
88 }
89
90 /**
91 * Simple Custom Post Order
92 */
93 if ( is_plugin_active( 'simple-custom-post-order/simple-custom-post-order.php' ) ) {
94 $options = get_option( 'scporder_options' );
95 $update = false;
96
97 if ( isset( $options['objects'] ) && is_array( $options['objects'] ) ) {
98 if ( in_array( 'wpm-testimonial', $options['objects'] ) ) {
99 $options['objects'] = array_diff( $options['objects'], array( 'wpm-testimonial' ) );
100 $update = true;
101 }
102 }
103
104 if ( isset( $options['tags'] ) && is_array( $options['tags'] ) ) {
105 if ( in_array( 'wpm-testimonial-category', $options['tags'] ) ) {
106 $options['tags'] = array_diff( $options['tags'], array( 'wpm-testimonial-category' ) );
107 $update = true;
108 }
109 }
110
111 if ( $update )
112 update_option( 'scporder_options', $options );
113 }
114
115 }
116 add_action( 'admin_init', 'wpmtst_deny_plugins_init', 200 );
117