Version Description
Release Date - 2022-7-26
- IWP-477 Fix bug that created html entities in JavaScript code
- IWP-478 Fix bug that split a code between the head and body
Download this release
Release Info
Developer | data443 |
Plugin | Tracking Code Manager |
Version | 2.0.13 |
Comparing to | |
See all releases |
Code changes from version 2.0.11 to 2.0.13
- assets/css/style.css +0 -1
- includes/admin/AdminOptions.php +11 -0
- includes/classes/core/Manager.php +133 -106
- includes/classes/ui/Form.php +2 -2
- includes/classes/utils/Options.php +18 -3
- index.php +25 -3
- languages/Lang.txt +4 -2
- readme.txt +13 -1
assets/css/style.css
CHANGED
@@ -48,7 +48,6 @@
|
|
48 |
color:#555;
|
49 |
background-color:#f8f8f8;
|
50 |
width:550px;
|
51 |
-
height:350px;
|
52 |
}
|
53 |
|
54 |
.tcmp-form {
|
48 |
color:#555;
|
49 |
background-color:#f8f8f8;
|
50 |
width:550px;
|
|
|
51 |
}
|
52 |
|
53 |
.tcmp-form {
|
includes/admin/AdminOptions.php
CHANGED
@@ -12,8 +12,19 @@ function tcmp_ui_admin_options() {
|
|
12 |
|
13 |
if ( $tcmp->check->nonce( 'tcmp_admin_options' ) ) {
|
14 |
$tcmp->options->setModifySuperglobalVariable( $tcmp->utils->iqs( 'checkbox' ) );
|
|
|
|
|
|
|
15 |
}
|
16 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
17 |
$tcmp->form->p( __( 'Enable option to change cache behavior' ) );
|
18 |
|
19 |
$modify = $tcmp->options->getModifySuperglobalVariable();
|
12 |
|
13 |
if ( $tcmp->check->nonce( 'tcmp_admin_options' ) ) {
|
14 |
$tcmp->options->setModifySuperglobalVariable( $tcmp->utils->iqs( 'checkbox' ) );
|
15 |
+
$tcmp->options->setAdditionalRecognizedTags( $tcmp->utils->qs( 'tags' ) );
|
16 |
+
$tcmp->options->setAdditionalRecognizedAttributes( $tcmp->utils->qs( 'attributes' ) );
|
17 |
+
tcmp_add_additional_tags_atts();
|
18 |
}
|
19 |
|
20 |
+
$tcmp->form->p( __( 'Add additional tags and/or attributes to the code whitelist' ) );
|
21 |
+
|
22 |
+
$tags = $tcmp->options->getAdditionalRecognizedTags();
|
23 |
+
$attributes = $tcmp->options->getAdditionalRecognizedAttributes();
|
24 |
+
|
25 |
+
$tcmp->form->textarea('tags', $tags, array('rows' => 2,));
|
26 |
+
$tcmp->form->textarea('attributes', $attributes, array('rows' => 2,));
|
27 |
+
|
28 |
$tcmp->form->p( __( 'Enable option to change cache behavior' ) );
|
29 |
|
30 |
$modify = $tcmp->options->getModifySuperglobalVariable();
|
includes/classes/core/Manager.php
CHANGED
@@ -309,18 +309,19 @@ class TCMP_Manager {
|
|
309 |
global $tcmp;
|
310 |
|
311 |
$text = '';
|
|
|
312 |
switch ( $position ) {
|
313 |
case TCMP_POSITION_HEAD:
|
314 |
-
$
|
315 |
break;
|
316 |
case TCMP_POSITION_BODY:
|
317 |
-
$
|
318 |
break;
|
319 |
case TCMP_POSITION_FOOTER:
|
320 |
-
$
|
321 |
break;
|
322 |
case TCMP_POSITION_CONVERSION:
|
323 |
-
$
|
324 |
break;
|
325 |
}
|
326 |
|
@@ -329,113 +330,20 @@ class TCMP_Manager {
|
|
329 |
$codes = $tcmp->manager->get_codes( $position, $post, $args );
|
330 |
if ( is_array( $codes ) && count( $codes ) > 0 ) {
|
331 |
$version = TCMP_PLUGIN_VERSION;
|
332 |
-
|
333 |
-
echo "\n<!--BEGIN: TRACKING CODE (v$version) MANAGER BY INTELLYWP.COM IN $text//-->";
|
334 |
foreach ( $codes as $v ) {
|
335 |
-
|
|
|
|
|
|
|
|
|
|
|
336 |
}
|
337 |
-
|
338 |
-
$text = ob_get_contents();
|
339 |
-
ob_end_clean();
|
340 |
|
341 |
$purchase = $tcmp->options->getEcommercePurchase();
|
342 |
if ( false != $purchase && intval( $tcmp->options->getLicenseSiteCount() ) > 0 ) {
|
343 |
-
|
344 |
-
$purchase->user_id = intval( $purchase->user_id );
|
345 |
-
if ( $purchase->user_id > 0 ) {
|
346 |
-
$user = get_user_by( 'id', $purchase->user_id );
|
347 |
-
if ( ! is_null( $user ) && false != $user && get_class( $user ) == 'WP_User' ) {
|
348 |
-
/* @var $user WP_User */
|
349 |
-
$purchase->email = $user->user_email;
|
350 |
-
$purchase->fullname = $user->user_firstname;
|
351 |
-
if ( '' != $user->user_lastname ) {
|
352 |
-
$purchase->fullname .= ' ' . $user->user_lastname;
|
353 |
-
}
|
354 |
-
}
|
355 |
-
}
|
356 |
-
|
357 |
-
$purchase->total = floatval( $purchase->total );
|
358 |
-
$purchase->amount = floatval( $purchase->amount );
|
359 |
-
$purchase->tax = floatval( $purchase->tax );
|
360 |
-
|
361 |
-
$fields = array(
|
362 |
-
'ORDERID' => $purchase->order_id,
|
363 |
-
'CURRENCY' => $purchase->currency,
|
364 |
-
'FULLNAME' => $purchase->fullname,
|
365 |
-
'EMAIL' => $purchase->email,
|
366 |
-
'PRODUCTS' => $purchase->products,
|
367 |
-
'AMOUNT' => $purchase->amount,
|
368 |
-
'TOTAL' => $purchase->total,
|
369 |
-
'TAX' => $purchase->tax,
|
370 |
-
);
|
371 |
-
|
372 |
-
$sep = '@@';
|
373 |
-
$buffer = '';
|
374 |
-
$previous = 0;
|
375 |
-
$start = strpos( $text, $sep );
|
376 |
-
if ( false == $start ) {
|
377 |
-
$buffer = $text;
|
378 |
-
} else {
|
379 |
-
while ( false != $start ) {
|
380 |
-
$buffer .= $tcmp->utils->substr( $text, $previous, $start );
|
381 |
-
$end = strpos( $text, $sep, $start + strlen( $sep ) );
|
382 |
-
if ( false != $end ) {
|
383 |
-
$code = $tcmp->utils->substr( $text, $start + strlen( $sep ), $end );
|
384 |
-
$code = $tcmp->utils->to_array( $code );
|
385 |
-
if ( 1 == count( $code ) ) {
|
386 |
-
$code[] = '';
|
387 |
-
}
|
388 |
-
|
389 |
-
$v = false;
|
390 |
-
if ( isset( $fields[ $code[0] ] ) ) {
|
391 |
-
$v = $fields[ $code[0] ];
|
392 |
-
}
|
393 |
-
if ( is_null( $v ) || false == $v ) {
|
394 |
-
$v = $code[1];
|
395 |
-
}
|
396 |
-
if ( is_numeric( $v ) ) {
|
397 |
-
$v = floatval( $v );
|
398 |
-
$v = round( $v, 2 );
|
399 |
-
switch ( $code[0] ) {
|
400 |
-
case 'TOTAL':
|
401 |
-
case 'AMOUNT':
|
402 |
-
case 'TAX':
|
403 |
-
$v = number_format( $v, 2, '.', '' );
|
404 |
-
break;
|
405 |
-
default:
|
406 |
-
$v = intval( $v );
|
407 |
-
break;
|
408 |
-
}
|
409 |
-
} elseif ( is_array( $v ) ) {
|
410 |
-
$a = '';
|
411 |
-
foreach ( $v as $t ) {
|
412 |
-
$t = str_replace( ',', '', $t );
|
413 |
-
if ( '' != $a ) {
|
414 |
-
$a .= ',';
|
415 |
-
}
|
416 |
-
$a .= $t;
|
417 |
-
}
|
418 |
-
$v = $a;
|
419 |
-
}
|
420 |
-
$v = str_replace( "'", '', $v );
|
421 |
-
$v = str_replace( '"', '', $v );
|
422 |
-
$buffer .= $v;
|
423 |
-
|
424 |
-
$previous = $end + strlen( $sep );
|
425 |
-
$start = strpos( $text, $sep, $previous );
|
426 |
-
} else {
|
427 |
-
$buffer .= $tcmp->utils->substr( $text, $start );
|
428 |
-
$previous = false;
|
429 |
-
$start = false;
|
430 |
-
}
|
431 |
-
}
|
432 |
-
|
433 |
-
if ( false != $previous && $previous < strlen( $text ) ) {
|
434 |
-
$code = $tcmp->utils->substr( $text, $previous );
|
435 |
-
$buffer .= $code;
|
436 |
-
}
|
437 |
-
}
|
438 |
-
$text = $buffer;
|
439 |
}
|
440 |
echo $this->esc_js_code( $text );
|
441 |
}
|
@@ -447,9 +355,128 @@ class TCMP_Manager {
|
|
447 |
$text = str_replace( '<', '<', $text );
|
448 |
$text = str_replace( '>', '>', $text );
|
449 |
$text = str_replace( '&', '&', $text );
|
|
|
|
|
450 |
return $text;
|
451 |
}
|
452 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
453 |
//return snippets that match with options
|
454 |
public function get_conversion_snippets( $options = null ) {
|
455 |
global $tcmp;
|
309 |
global $tcmp;
|
310 |
|
311 |
$text = '';
|
312 |
+
$position_text = '';
|
313 |
switch ( $position ) {
|
314 |
case TCMP_POSITION_HEAD:
|
315 |
+
$position_text = 'HEAD';
|
316 |
break;
|
317 |
case TCMP_POSITION_BODY:
|
318 |
+
$position_text = 'BODY';
|
319 |
break;
|
320 |
case TCMP_POSITION_FOOTER:
|
321 |
+
$position_text = 'FOOTER';
|
322 |
break;
|
323 |
case TCMP_POSITION_CONVERSION:
|
324 |
+
$position_text = 'CONVERSION';
|
325 |
break;
|
326 |
}
|
327 |
|
330 |
$codes = $tcmp->manager->get_codes( $position, $post, $args );
|
331 |
if ( is_array( $codes ) && count( $codes ) > 0 ) {
|
332 |
$version = TCMP_PLUGIN_VERSION;
|
333 |
+
$text = "\n<!--BEGIN: TRACKING CODE (v$version) MANAGER BY INTELLYWP.COM IN $position_text//-->";
|
|
|
334 |
foreach ( $codes as $v ) {
|
335 |
+
$fixed = $this->fix_google_tag_corruption( $v );
|
336 |
+
if ( strlen( $fixed ) > 0 ) {
|
337 |
+
$text .= "\n$fixed";
|
338 |
+
} else {
|
339 |
+
$text .= "\n$v";
|
340 |
+
}
|
341 |
}
|
342 |
+
$text .= "\n<!--END: https://wordpress.org/plugins/tracking-code-manager IN $position_text//-->";
|
|
|
|
|
343 |
|
344 |
$purchase = $tcmp->options->getEcommercePurchase();
|
345 |
if ( false != $purchase && intval( $tcmp->options->getLicenseSiteCount() ) > 0 ) {
|
346 |
+
$text = $this->insert_dynamic_conversion_values( $purchase, $text );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
347 |
}
|
348 |
echo $this->esc_js_code( $text );
|
349 |
}
|
355 |
$text = str_replace( '<', '<', $text );
|
356 |
$text = str_replace( '>', '>', $text );
|
357 |
$text = str_replace( '&', '&', $text );
|
358 |
+
$text = str_replace( '"', '"', $text );
|
359 |
+
$text = str_replace( ''', "'", $text );
|
360 |
return $text;
|
361 |
}
|
362 |
|
363 |
+
private function fix_google_tag_corruption( $text ) {
|
364 |
+
// confirm that we're not corrupting the google tag manger script, but if it's bad, fix it and update the db
|
365 |
+
$pattern = "/<a href=(?:'|\")(https:\\/\\/www\\.googletagmanager\\.com\\/gtag\\/js\\?id=[a-zA-Z0-9\\-]+)(?:'|\")>(https:\\/\\/www\\.googletagmanager\\.com\\/gtag\\/js\\?id=[a-zA-Z0-9\\-]+)<\\/a>/";
|
366 |
+
$matches = null;
|
367 |
+
preg_match( $pattern, $text, $matches );
|
368 |
+
if ( isset( $matches[1] ) && isset( $matches[2] ) && strlen( $matches[1] ) > 0 && $matches[1] === $matches[2] ) {
|
369 |
+
$new = preg_replace( $pattern, '<script async src="$1"></script>', $text );
|
370 |
+
$key = 'TCM_google_tag_fix';
|
371 |
+
$count = get_option( $key, 0 );
|
372 |
+
if ( 0 == $count ) {
|
373 |
+
update_option( $key, ++$count );
|
374 |
+
}
|
375 |
+
$new .= "\n<!-- tag fix: ".$count." -->";
|
376 |
+
return $new;
|
377 |
+
}
|
378 |
+
return '';
|
379 |
+
}
|
380 |
+
|
381 |
+
private function insert_dynamic_conversion_values( $purchase, $text ) {
|
382 |
+
global $tcmp;
|
383 |
+
$purchase->user_id = intval( $purchase->user_id );
|
384 |
+
if ( $purchase->user_id > 0 ) {
|
385 |
+
$user = get_user_by( 'id', $purchase->user_id );
|
386 |
+
if ( ! is_null( $user ) && false != $user && get_class( $user ) == 'WP_User' ) {
|
387 |
+
/* @var $user WP_User */
|
388 |
+
$purchase->email = $user->user_email;
|
389 |
+
$purchase->fullname = $user->user_firstname;
|
390 |
+
if ( '' != $user->user_lastname ) {
|
391 |
+
$purchase->fullname .= ' ' . $user->user_lastname;
|
392 |
+
}
|
393 |
+
}
|
394 |
+
}
|
395 |
+
|
396 |
+
$purchase->total = floatval( $purchase->total );
|
397 |
+
$purchase->amount = floatval( $purchase->amount );
|
398 |
+
$purchase->tax = floatval( $purchase->tax );
|
399 |
+
|
400 |
+
$fields = array(
|
401 |
+
'ORDERID' => $purchase->order_id,
|
402 |
+
'CURRENCY' => $purchase->currency,
|
403 |
+
'FULLNAME' => $purchase->fullname,
|
404 |
+
'EMAIL' => $purchase->email,
|
405 |
+
'PRODUCTS' => $purchase->products,
|
406 |
+
'AMOUNT' => $purchase->amount,
|
407 |
+
'TOTAL' => $purchase->total,
|
408 |
+
'TAX' => $purchase->tax,
|
409 |
+
);
|
410 |
+
|
411 |
+
$sep = '@@';
|
412 |
+
$buffer = '';
|
413 |
+
$previous = 0;
|
414 |
+
$start = strpos( $text, $sep );
|
415 |
+
if ( false == $start ) {
|
416 |
+
$buffer = $text;
|
417 |
+
} else {
|
418 |
+
while ( false != $start ) {
|
419 |
+
$buffer .= $tcmp->utils->substr( $text, $previous, $start );
|
420 |
+
$end = strpos( $text, $sep, $start + strlen( $sep ) );
|
421 |
+
if ( false != $end ) {
|
422 |
+
$code = $tcmp->utils->substr( $text, $start + strlen( $sep ), $end );
|
423 |
+
$code = $tcmp->utils->to_array( $code );
|
424 |
+
if ( 1 == count( $code ) ) {
|
425 |
+
$code[] = '';
|
426 |
+
}
|
427 |
+
|
428 |
+
$v = false;
|
429 |
+
if ( isset( $fields[ $code[0] ] ) ) {
|
430 |
+
$v = $fields[ $code[0] ];
|
431 |
+
}
|
432 |
+
if ( is_null( $v ) || false == $v ) {
|
433 |
+
$v = $code[1];
|
434 |
+
}
|
435 |
+
if ( is_numeric( $v ) ) {
|
436 |
+
$v = floatval( $v );
|
437 |
+
$v = round( $v, 2 );
|
438 |
+
switch ( $code[0] ) {
|
439 |
+
case 'TOTAL':
|
440 |
+
case 'AMOUNT':
|
441 |
+
case 'TAX':
|
442 |
+
$v = number_format( $v, 2, '.', '' );
|
443 |
+
break;
|
444 |
+
default:
|
445 |
+
$v = intval( $v );
|
446 |
+
break;
|
447 |
+
}
|
448 |
+
} elseif ( is_array( $v ) ) {
|
449 |
+
$a = '';
|
450 |
+
foreach ( $v as $t ) {
|
451 |
+
$t = str_replace( ',', '', $t );
|
452 |
+
if ( '' != $a ) {
|
453 |
+
$a .= ',';
|
454 |
+
}
|
455 |
+
$a .= $t;
|
456 |
+
}
|
457 |
+
$v = $a;
|
458 |
+
}
|
459 |
+
$v = str_replace( "'", '', $v );
|
460 |
+
$v = str_replace( '"', '', $v );
|
461 |
+
$buffer .= $v;
|
462 |
+
|
463 |
+
$previous = $end + strlen( $sep );
|
464 |
+
$start = strpos( $text, $sep, $previous );
|
465 |
+
} else {
|
466 |
+
$buffer .= $tcmp->utils->substr( $text, $start );
|
467 |
+
$previous = false;
|
468 |
+
$start = false;
|
469 |
+
}
|
470 |
+
}
|
471 |
+
|
472 |
+
if ( false != $previous && $previous < strlen( $text ) ) {
|
473 |
+
$code = $tcmp->utils->substr( $text, $previous );
|
474 |
+
$buffer .= $code;
|
475 |
+
}
|
476 |
+
}
|
477 |
+
return $buffer;
|
478 |
+
}
|
479 |
+
|
480 |
//return snippets that match with options
|
481 |
public function get_conversion_snippets( $options = null ) {
|
482 |
global $tcmp;
|
includes/classes/ui/Form.php
CHANGED
@@ -83,13 +83,13 @@ class TCMP_Form {
|
|
83 |
$a_class = '';
|
84 |
|
85 |
?>
|
86 |
-
<label for="<?php echo esc_attr( $for ); ?>" <?php echo
|
87 |
<?php
|
88 |
if ( $this->left_tags ) {
|
89 |
$this->tag();
|
90 |
}
|
91 |
?>
|
92 |
-
<span style="float:left; margin-right:5px;" class="<?php echo esc_attr( $a_class ); ?>"><?php echo
|
93 |
<?php
|
94 |
if ( ! $this->left_tags ) {
|
95 |
$this->tag();
|
83 |
$a_class = '';
|
84 |
|
85 |
?>
|
86 |
+
<label for="<?php echo esc_attr( $for ); ?>" <?php echo wp_kses_post( $other_text ); ?> >
|
87 |
<?php
|
88 |
if ( $this->left_tags ) {
|
89 |
$this->tag();
|
90 |
}
|
91 |
?>
|
92 |
+
<span style="float:left; margin-right:5px;" class="<?php echo esc_attr( $a_class ); ?>"><?php echo wp_kses_post( $label ); ?></span>
|
93 |
<?php
|
94 |
if ( ! $this->left_tags ) {
|
95 |
$this->tag();
|
includes/classes/utils/Options.php
CHANGED
@@ -124,9 +124,6 @@ class TCMP_Options {
|
|
124 |
} elseif ( is_string( $value ) ) {
|
125 |
global $tcmp_allowed_html_tags;
|
126 |
$value = wp_kses( $value, $tcmp_allowed_html_tags );
|
127 |
-
$value = str_replace( '<', '<', $value );
|
128 |
-
$value = str_replace( '>', '>', $value );
|
129 |
-
$value = str_replace( '&', '&', $value );
|
130 |
} else {
|
131 |
// do nothing ... could be a video or graphics object
|
132 |
}
|
@@ -457,6 +454,24 @@ class TCMP_Options {
|
|
457 |
$this->setOption( 'MetaboxPostTypes', $values );
|
458 |
}
|
459 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
460 |
// Modify Superglobal Variable
|
461 |
public function getModifySuperglobalVariable() {
|
462 |
return $this->getOption( 'ModifySuperglobalVariable', false );
|
124 |
} elseif ( is_string( $value ) ) {
|
125 |
global $tcmp_allowed_html_tags;
|
126 |
$value = wp_kses( $value, $tcmp_allowed_html_tags );
|
|
|
|
|
|
|
127 |
} else {
|
128 |
// do nothing ... could be a video or graphics object
|
129 |
}
|
454 |
$this->setOption( 'MetaboxPostTypes', $values );
|
455 |
}
|
456 |
|
457 |
+
// Add additional recognized tags and attributes
|
458 |
+
public function getAdditionalRecognizedTags() {
|
459 |
+
return $this->getOption( 'additionalRecognizedTags', 'script' );
|
460 |
+
}
|
461 |
+
public function getAdditionalRecognizedAttributes() {
|
462 |
+
return $this->getOption( 'additionalRecognizedAttributes', 'data-cbid,data-blockingmode' );
|
463 |
+
}
|
464 |
+
public function setAdditionalRecognizedTags( $text ) {
|
465 |
+
if (is_string($text)) {
|
466 |
+
$this->setOption( 'additionalRecognizedTags', $text );
|
467 |
+
}
|
468 |
+
}
|
469 |
+
public function setAdditionalRecognizedAttributes( $text ) {
|
470 |
+
if (is_string($text)) {
|
471 |
+
$this->setOption( 'additionalRecognizedAttributes', $text );
|
472 |
+
}
|
473 |
+
}
|
474 |
+
|
475 |
// Modify Superglobal Variable
|
476 |
public function getModifySuperglobalVariable() {
|
477 |
return $this->getOption( 'ModifySuperglobalVariable', false );
|
index.php
CHANGED
@@ -5,8 +5,8 @@ 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:
|
9 |
-
Version: 2.0.
|
10 |
Requires at least: 3.6.0
|
11 |
Requires PHP: 5.6
|
12 |
*/
|
@@ -27,7 +27,7 @@ define( 'TCMP_PLUGIN_PREFIX', 'TCMP_' );
|
|
27 |
define( 'TCMP_PLUGIN_FILE', __FILE__ );
|
28 |
define( 'TCMP_PLUGIN_SLUG', 'tracking-code-manager' );
|
29 |
define( 'TCMP_PLUGIN_NAME', 'Tracking Code Manager' );
|
30 |
-
define( 'TCMP_PLUGIN_VERSION', '2.0.
|
31 |
define( 'TCMP_PLUGIN_AUTHOR', 'IntellyWP' );
|
32 |
|
33 |
define( 'TCMP_PLUGIN_DIR', dirname( __FILE__ ) . '/' );
|
@@ -168,6 +168,28 @@ global $tcmp;
|
|
168 |
$tcmp = new TCMP_Singleton();
|
169 |
$tcmp->init();
|
170 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
171 |
function tcmp_qs( $name, $default = '' ) {
|
172 |
global $tcmp;
|
173 |
$result = $tcmp->utils->qs( $name, $default );
|
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: support@data443.com
|
9 |
+
Version: 2.0.13
|
10 |
Requires at least: 3.6.0
|
11 |
Requires PHP: 5.6
|
12 |
*/
|
27 |
define( 'TCMP_PLUGIN_FILE', __FILE__ );
|
28 |
define( 'TCMP_PLUGIN_SLUG', 'tracking-code-manager' );
|
29 |
define( 'TCMP_PLUGIN_NAME', 'Tracking Code Manager' );
|
30 |
+
define( 'TCMP_PLUGIN_VERSION', '2.0.13' );
|
31 |
define( 'TCMP_PLUGIN_AUTHOR', 'IntellyWP' );
|
32 |
|
33 |
define( 'TCMP_PLUGIN_DIR', dirname( __FILE__ ) . '/' );
|
168 |
$tcmp = new TCMP_Singleton();
|
169 |
$tcmp->init();
|
170 |
|
171 |
+
function tcmp_add_additional_tags_atts() {
|
172 |
+
global $tcmp;
|
173 |
+
global $tcmp_allowed_html_tags;
|
174 |
+
global $tcmp_allowed_atts;
|
175 |
+
$tags = explode( ",", sanitize_text_field( $tcmp->options->getAdditionalRecognizedTags() ) );
|
176 |
+
$attrs = explode( ",", sanitize_text_field( $tcmp->options->getAdditionalRecognizedAttributes() ) );
|
177 |
+
|
178 |
+
foreach ( $tags as $tag ) {
|
179 |
+
$tag = trim( $tag );
|
180 |
+
$current_attrs = $tcmp_allowed_html_tags[$tag];
|
181 |
+
foreach ( $attrs as $k ) {
|
182 |
+
$k = trim( $k );
|
183 |
+
if ( !isset( $current_attrs[$k]) ) {
|
184 |
+
$current_attrs[$k] = array();
|
185 |
+
}
|
186 |
+
}
|
187 |
+
$tcmp_allowed_html_tags[$tag] = $current_attrs;
|
188 |
+
}
|
189 |
+
}
|
190 |
+
|
191 |
+
tcmp_add_additional_tags_atts();
|
192 |
+
|
193 |
function tcmp_qs( $name, $default = '' ) {
|
194 |
global $tcmp;
|
195 |
$result = $tcmp->utils->qs( $name, $default );
|
languages/Lang.txt
CHANGED
@@ -3,6 +3,8 @@ AboutText1=We are Stefan and Alex, two guys in love with Wordpress, coding and m
|
|
3 |
AboutText2=Feel free to reach us by the feedback form below.
|
4 |
AboutTitle=We make Intelly plugins for your Intelly site
|
5 |
AdminOptions.checkbox=Modify Superglobal Variable
|
|
|
|
|
6 |
Actions=
|
7 |
ActivateError=Errors activating key. Network problem or wrong password
|
8 |
ActivateSuccess1=License key "{0}" successfully activated
|
@@ -43,7 +45,7 @@ Editor.NoEcommerceFound1=No compatible ecommerce found!
|
|
43 |
Editor.NoEcommerceFound2=Currently we are compatible with <b>{0}</b>
|
44 |
Editor.PositionBlocked=Select [ALL] to track every purchase, or select from the the list if you'd like track sales only of certain products.
|
45 |
Editor.active=Active?
|
46 |
-
Editor.code=Paste your Tracking Code here
|
47 |
Editor.deviceType=Show only on device
|
48 |
Editor.deviceType.all=[All]
|
49 |
Editor.deviceType.desktop=Desktop
|
@@ -110,7 +112,7 @@ LicenseSection=License information
|
|
110 |
LicenseSectionSubtitle=Insert the activation key received by email in the text below to see all the settings
|
111 |
Priority.tcmpHookPriority=Priority
|
112 |
PrioritySection=Priority Setting
|
113 |
-
PrioritySectionSubtitle=Change the priority used to insert the scripts onto the page. (Default priority is 10, 1 is the highest priority and lower priorities are higher numbers.)
|
114 |
Manager=
|
115 |
ManagerTitle=Welcome to "<b>Tracking Code Manager</b> (v.{0})", a <a href="https://data443.com/" target="_blank"><b>Data443</b></a> plugin.
|
116 |
MetaboxSection=Metabox information
|
3 |
AboutText2=Feel free to reach us by the feedback form below.
|
4 |
AboutTitle=We make Intelly plugins for your Intelly site
|
5 |
AdminOptions.checkbox=Modify Superglobal Variable
|
6 |
+
AdminOptions.tags=Tags <small>(separate multiple values with a comma)</small>
|
7 |
+
AdminOptions.attributes=Attributes <small>(separate multiple values with a comma)</small>
|
8 |
Actions=
|
9 |
ActivateError=Errors activating key. Network problem or wrong password
|
10 |
ActivateSuccess1=License key "{0}" successfully activated
|
45 |
Editor.NoEcommerceFound2=Currently we are compatible with <b>{0}</b>
|
46 |
Editor.PositionBlocked=Select [ALL] to track every purchase, or select from the the list if you'd like track sales only of certain products.
|
47 |
Editor.active=Active?
|
48 |
+
Editor.code=Paste your Tracking Code here <small>(If your tag or attribute is filtered out, you can add it to the whitelist in the <i>Admin Options</i> tab.)</small>
|
49 |
Editor.deviceType=Show only on device
|
50 |
Editor.deviceType.all=[All]
|
51 |
Editor.deviceType.desktop=Desktop
|
112 |
LicenseSectionSubtitle=Insert the activation key received by email in the text below to see all the settings
|
113 |
Priority.tcmpHookPriority=Priority
|
114 |
PrioritySection=Priority Setting
|
115 |
+
PrioritySectionSubtitle=Change the priority used to insert the scripts onto the page. <small>(Default priority is 10, 1 is the highest priority and lower priorities are higher numbers.)</small>
|
116 |
Manager=
|
117 |
ManagerTitle=Welcome to "<b>Tracking Code Manager</b> (v.{0})", a <a href="https://data443.com/" target="_blank"><b>Data443</b></a> plugin.
|
118 |
MetaboxSection=Metabox information
|
readme.txt
CHANGED
@@ -3,7 +3,7 @@ Contributors: IntellyWP, Data443
|
|
3 |
Tags: adwords remarketing, analytics conversion tracking, conversion pixel, conversion tracking, conversion tracking adwords, conversion tracking pixel, conversion tracking script,Facebook Ads, facebook conversion pixel, facebook custom audience, facebook retargeting, google adwords, google analytics web tracking code, google tag manager, html snippet, html snippets, html tracking code, javascript snippet, javascript snippets, header and footer, pay per click tracking, pixel tracking code, remarketing, retargeting, snippets, Tag Management, track conversion, track conversions, tracking code, tracking codes, tracking script, woocommerce, edd, easy digital downloads, wp ecommerce, wp e-commerce, gdpr, tracking gdpr, privacy
|
4 |
Requires at least: 2.7
|
5 |
Tested up to: 6.0
|
6 |
-
Stable tag: 2.0.
|
7 |
Requires PHP: 5.6
|
8 |
|
9 |
A plugin to manage ALL of your tracking code and conversion pixels. Compatible with Facebook Ads, Google Adwords, WooCommerce, Easy Digital Downloads, ..
|
@@ -112,6 +112,18 @@ Have a look at the source code of your page (search for: Tracking Code Manager)
|
|
112 |
|
113 |
For detailed release notes, see our documentation here: [https://intellywp.com/docs/category/tracking-code-manager/](https://intellywp.com/docs/category/tracking-code-manager/).
|
114 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
115 |
= 2.0.11 =
|
116 |
*Release Date - 2022-7-13*
|
117 |
|
3 |
Tags: adwords remarketing, analytics conversion tracking, conversion pixel, conversion tracking, conversion tracking adwords, conversion tracking pixel, conversion tracking script,Facebook Ads, facebook conversion pixel, facebook custom audience, facebook retargeting, google adwords, google analytics web tracking code, google tag manager, html snippet, html snippets, html tracking code, javascript snippet, javascript snippets, header and footer, pay per click tracking, pixel tracking code, remarketing, retargeting, snippets, Tag Management, track conversion, track conversions, tracking code, tracking codes, tracking script, woocommerce, edd, easy digital downloads, wp ecommerce, wp e-commerce, gdpr, tracking gdpr, privacy
|
4 |
Requires at least: 2.7
|
5 |
Tested up to: 6.0
|
6 |
+
Stable tag: 2.0.13
|
7 |
Requires PHP: 5.6
|
8 |
|
9 |
A plugin to manage ALL of your tracking code and conversion pixels. Compatible with Facebook Ads, Google Adwords, WooCommerce, Easy Digital Downloads, ..
|
112 |
|
113 |
For detailed release notes, see our documentation here: [https://intellywp.com/docs/category/tracking-code-manager/](https://intellywp.com/docs/category/tracking-code-manager/).
|
114 |
|
115 |
+
= 2.0.13 =
|
116 |
+
*Release Date - 2022-7-26*
|
117 |
+
|
118 |
+
* IWP-477 Fix bug that created html entities in JavaScript code
|
119 |
+
* IWP-478 Fix bug that split a code between the head and body
|
120 |
+
|
121 |
+
= 2.0.12 =
|
122 |
+
*Release Date - 2022-7-15*
|
123 |
+
|
124 |
+
* IWP-466 Update contact email
|
125 |
+
* IWP-467 Provide input fields to modify the code tag and attribute whitelist
|
126 |
+
|
127 |
= 2.0.11 =
|
128 |
*Release Date - 2022-7-13*
|
129 |
|