PluginProbe ʕ •ᴥ•ʔ
Tracking Code Manager / 2.0.5
Tracking Code Manager v2.0.5
trunk 1.11.8 1.11.9 1.12.0 1.12.1 1.12.2 1.12.3 1.4 1.5 2.0.0 2.0.1 2.0.13 2.0.14 2.0.15 2.0.16 2.0.2 2.0.3 2.0.4 2.0.5 2.0.6 2.0.7 2.1.0 2.2.0 2.3.0 2.4.0 2.5.0 2.6.0
tracking-code-manager / index.php
tracking-code-manager Last commit date
assets 4 years ago includes 4 years ago languages 4 years ago autoload.php 4 years ago index.php 4 years ago readme.txt 4 years ago screenshot-1.png 11 years ago screenshot-2.png 11 years ago screenshot-3.png 11 years ago screenshot-4.png 11 years ago screenshot-5.png 11 years ago
index.php
125 lines
1 <?php
2 /*
3 Plugin Name: Tracking Code Manager
4 Plugin URI: http://intellywp.com/tracking-code-manager/
5 Description: A plugin to manage ALL your tracking code and conversion pixels, simply. Compatible with Facebook Ads, Google Adwords, WooCommerce, Easy Digital Downloads, WP eCommerce.
6 Author: Data443
7 Author URI: https://data443.com/
8 Email: info@intellywp.com
9 Version: 2.0.5
10 Requires at least: 3.6.0
11 Requires PHP: 7.3
12 */
13 if(defined('TCMP_PLUGIN_NAME')) {
14 function tcmp_admin_notices() {
15 global $tcmp; ?>
16 <div style="clear:both"></div>
17 <div class="error iwp" style="padding:10px;">
18 <?php $tcmp->Lang->P('PluginProAlreadyInstalled'); ?>
19 </div>
20 <div style="clear:both"></div>
21 <?php }
22 add_action('admin_notices', 'tcmp_admin_notices');
23 return;
24 }
25 define('TCMP_PLUGIN_PREFIX', 'TCMP_');
26 define('TCMP_PLUGIN_FILE',__FILE__);
27 define('TCMP_PLUGIN_SLUG', 'tracking-code-manager');
28 define('TCMP_PLUGIN_NAME', 'Tracking Code Manager');
29 define('TCMP_PLUGIN_VERSION', '2.0.5');
30 define('TCMP_PLUGIN_AUTHOR', 'IntellyWP');
31
32 define('TCMP_PLUGIN_DIR', dirname(__FILE__).'/');
33 define('TCMP_PLUGIN_ASSETS_URI', plugins_url( 'assets/', __FILE__ ));
34 define('TCMP_PLUGIN_IMAGES_URI', plugins_url( 'assets/images/', __FILE__ ));
35
36 define('TCMP_LOGGER', FALSE);
37 define('TCMP_AUTOSAVE_LANG', FALSE);
38
39 define('TCMP_QUERY_POSTS_OF_TYPE', 1);
40 define('TCMP_QUERY_POST_TYPES', 2);
41 define('TCMP_QUERY_CATEGORIES', 3);
42 define('TCMP_QUERY_TAGS', 4);
43 define('TCMP_QUERY_CONVERSION_PLUGINS', 5);
44 define('TCMP_QUERY_TAXONOMY_TYPES', 6);
45 define('TCMP_QUERY_TAXONOMIES_OF_TYPE', 7);
46
47 define('TCMP_INTELLYWP_SITE', 'http://www.intellywp.com/');
48 define('TCMP_INTELLYWP_ENDPOINT', TCMP_INTELLYWP_SITE.'wp-content/plugins/intellywp-manager/data.php');
49 define('TCMP_PAGE_FAQ', TCMP_INTELLYWP_SITE.'tracking-code-manager');
50 define('TCMP_PAGE_PREMIUM', TCMP_INTELLYWP_SITE.'tracking-code-manager');
51 define('TCMP_PAGE_MANAGER', admin_url().'options-general.php?page='.TCMP_PLUGIN_SLUG);
52 define('TCMP_PLUGIN_URI', plugins_url('/', __FILE__ ));
53
54 define('TCMP_POSITION_HEAD', 0);
55 define('TCMP_POSITION_BODY', 1);
56 define('TCMP_POSITION_FOOTER', 2);
57 define('TCMP_POSITION_CONVERSION', 3);
58
59 define('TCMP_TRACK_MODE_CODE', 0);
60 define('TCMP_TRACK_PAGE_ALL', 0);
61 define('TCMP_TRACK_PAGE_SPECIFIC', 1);
62
63 define('TCMP_DEVICE_TYPE_MOBILE', 'mobile');
64 define('TCMP_DEVICE_TYPE_TABLET', 'tablet');
65 define('TCMP_DEVICE_TYPE_DESKTOP', 'desktop');
66 define('TCMP_DEVICE_TYPE_ALL', 'all');
67
68 define('TCMP_HOOK_PRIORITY_DEFAULT', 10);
69
70 define('TCMP_TAB_EDITOR', 'editor');
71 define('TCMP_TAB_EDITOR_URI', TCMP_PAGE_MANAGER.'&tab='.TCMP_TAB_EDITOR);
72 define('TCMP_TAB_MANAGER', 'manager');
73 define('TCMP_TAB_MANAGER_URI', TCMP_PAGE_MANAGER.'&tab='.TCMP_TAB_MANAGER);
74 define('TCMP_TAB_SETTINGS', 'settings');
75 define('TCMP_TAB_SETTINGS_URI', TCMP_PAGE_MANAGER.'&tab='.TCMP_TAB_SETTINGS);
76 define('TCMP_TAB_DOCS', 'docs');
77 define('TCMP_TAB_DOCS_URI', 'http://intellywp.com/docs/category/tracking-code-manager/');
78 define('TCMP_TAB_DOCS_DCV_URI', 'https://data443.atlassian.net/servicedesk/customer/kb/view/947486813');
79 define('TCMP_TAB_ABOUT', 'about');
80 define('TCMP_TAB_ABOUT_URI', TCMP_PAGE_MANAGER.'&tab='.TCMP_TAB_ABOUT);
81 define('TCMP_TAB_WHATS_NEW', 'whatsnew');
82 define('TCMP_TAB_WHATS_NEW_URI', TCMP_PAGE_MANAGER.'&tab='.TCMP_TAB_WHATS_NEW);
83
84 define('TCMP_SNIPPETS_LIMIT', 6);
85
86 include_once(dirname(__FILE__).'/autoload.php');
87 tcmp_include_php(dirname(__FILE__).'/includes/');
88
89 global $tcmp;
90 $tcmp=new TCMP_Singleton();
91 $tcmp->init();
92
93 function TCMP_QS($name, $default='') {
94 global $tcmp;
95 $result=$tcmp->Utils->qs($name, $default);
96 return $result;
97 }
98 //SANITIZED METHODS
99 function TCMP_SQS($name, $default='') {
100 $result=TCMP_QS($name, $default);
101 $result=sanitize_text_field($result);
102 return $result;
103 }
104 function TCMP_ISQS($name, $default=0) {
105 $result=TCMP_SQS($name, $default);
106 $result=floatval($result);
107 return $result;
108 }
109 function TCMP_BSQS($name, $default=0) {
110 global $tcmp;
111 $result=$tcmp->Utils->bqs($name, $default);
112 return $result;
113 }
114 function TCMP_ASQS($name, $default=array()) {
115 $result=TCMP_QS($name, $default);
116 if(is_array($result)) {
117 foreach ($result as $k=>$v) {
118 $result[$k]=sanitize_text_field($v);
119 }
120 } else {
121 $result=sanitize_text_field($result);
122 }
123 return $result;
124 }
125