first commit

This commit is contained in:
2024-11-10 21:08:49 +01:00
commit 0d932ce5ee
14455 changed files with 2567501 additions and 0 deletions

View File

@@ -0,0 +1,303 @@
<?php
namespace PixelYourSite;
if ( ! defined( 'ABSPATH' ) ) {
exit; // Exit if accessed directly.
}
?>
<!-- Consent Magic -->
<div class="card card-static">
<div class="card-header">
Consent Magic - Recommended
</div>
<div class="card-body">
<?php if (isConsentMagicPluginInstalled()) : ?>
<?php if (isConsentMagicPluginActivated()) : ?>
<div class="row">
<div class="col">
Manage your consent settings with
<?php if (isConsentMagicPluginLicenceActivated()) { ?>
<a href="<?=admin_url("admin.php?page=consent-magic")?>">Consent Magic.</a>
<?php } else { ?>
<a href="<?=admin_url("admin.php?page=cs-license")?>">Consent Magic.</a>
<?php } ?>
</div>
</div>
<?php else: ?>
<div class="row">
<div class="col">
You have Consent Magic installed, but its not activated yet. Go to the Plugins page and activate
<a href="<?=admin_url("plugins.php")?>">Consent Magic.</a>
</div>
</div>
<?php endif; ?>
<?php else: ?>
<div class="row">
<div class="col">
<p>Ask for consent the right way, block scripts and cookies when required.</p>
<p><strong>Manage different type of consent:</strong></p>
<ul class="pys_list">
<li><strong>Ask before tracking:</strong> show a consent message and block the tracking scripts before the
visitor expresses consent - ideal for GDPR.</li>
<li><strong>Inform and opt out:</strong> show a consent message, and block the tracking scripts if the visitor
doesnt agree to tracking - ideal for CCPA.</li>
<li><strong>Just inform:</strong> show a non-intrusive message informing your visitors about tracking.</li>
</ul>
<p><strong>Use geo-targeted rules:</strong></p>
<p>Target your visitors with the right rule based on their location. Rules can have different consent types
and different content. The plugin comes with the ready-made rules:</p>
<ul class="pys_list">
<li><strong>GDPR rule:</strong> targets visitors from GDPR countries, and uses Ask before tracking consent
type.</li>
<li><strong>CCPA rule:</strong> targets visitors from California, and uses Inform and opt-out consent type.</li>
<li><strong>Rest of the world rule:</strong> targets visitors from other locations and uses Just inform consent
type</li>
<li><strong>Your own rule:</strong> create any rules you need, target any countries, and use custom text for them.</li>
</ul>
</div>
</div>
<div class="row justify-content-center">
<div class="col-4">
<a href="https://www.pixelyoursite.com/plugins/consentmagic/?utm_source=pixelyoursite-free&utm_medium=pixelyoursite-free&utm_campaign=pixelyoursite-free&utm_content=pixelyoursite-free&utm_term=pixelyoursite-free" target="_blank" class="btn btn-sm pys_btn_orange">
Lean more about Consent Magic
</a>
</div>
</div>
<?php endif; ?>
</div>
</div>
<!-- Video -->
<div class="card card-static">
<div class="card-header">
Recommended Consent Videos:
</div>
<div class="card-body">
<div class="row">
<div class="col">
<p><a href="https://www.youtube.com/watch?v=uXTpgFu2V-E" target="_blank">The biggest problem with consent messages (7:02 min) - watch now</a></p>
<p><a href="https://www.youtube.com/watch?v=ZOlNbIPS_Uc" target="_blank">Target your visitors with the right consent rule (12:29 min) - watch now</a></p>
<p><a href="https://www.youtube.com/watch?v=P8CLxslSPDk" target="_blank">The right to change your mind (2:46 min) - watch now</a></p>
<p><a href="https://www.youtube.com/watch?v=PsKdCkKNeLU" target="_blank">Facebook Conversion API and the Consent Problem (9:25 min) - watch now</a></p>
</div>
</div>
</div>
</div>
<h2 class="section-title">Other consent plugins:</h2>
<!-- Cookiebot -->
<div class="card">
<div class="card-header">
<?php if ( ! isCookiebotPluginActivated() ) : ?>
Cookiebot <span class="text-danger">[not detected]</span><?php cardCollapseBtn(); ?>
<?php else: ?>
Cookiebot <span class="text-success">[detected]</span><?php cardCollapseBtn(); ?>
<?php endif; ?>
</div>
<div class="card-body">
<div class="row">
<div class="col">
<p>This is a complete premium solution that also offers a free plan for websites with under 100 pages.
For implementation, we suggest you follow their documentation.</p>
<p class="mb-0">Website: <a href="https://cookiebot.com" target="_blank">https://cookiebot.com</a></p>
<p class="mb-0">Plugin: <a href="https://wordpress.org/plugins/cookiebot/" target="_blank">https://wordpress.org/plugins/cookiebot/</a></p>
</div>
</div>
<div class="row mt-3">
<div class="col">
<?php PYS()->render_switcher_input( 'gdpr_cookiebot_integration_enabled', false,
! isCookiebotPluginActivated() ); ?>
<h4 class="switcher-label">Enable Cookiebot integration</h4>
</div>
</div>
<div class="row mt-3">
<div class="col-4">
<label class="label-inline">Meta Pixel (formerly Facebook Pixel) consent category:</label>
</div>
<div class="col-4">
<?php PYS()->render_text_input( 'gdpr_cookiebot_facebook_consent_category',
'Enter consent category', ! isCookiebotPluginActivated() ); ?>
</div>
</div>
<div class="row mt-3">
<div class="col-4">
<label class="label-inline">Google Analytics consent category:</label>
</div>
<div class="col-4">
<?php PYS()->render_text_input( 'gdpr_cookiebot_analytics_consent_category',
'Enter consent category', ! isCookiebotPluginActivated() ); ?>
</div>
<div class="col-4">
* If you have advertising features enabled, enter "marketing"
</div>
</div>
<div class="row mt-3">
<div class="col-4">
<label class="label-inline">Google Ads consent category:</label>
</div>
<div class="col-4">
<?php PYS()->render_text_input( 'gdpr_cookiebot_google_ads_consent_category',
'Enter consent category', ! isCookiebotPluginActivated() ); ?>
</div>
</div>
<div class="row mt-3">
<div class="col-4">
<label class="label-inline">Pinterest Tag consent category:</label>
</div>
<div class="col-4">
<?php PYS()->render_text_input( 'gdpr_cookiebot_pinterest_consent_category',
'Enter consent category', ! isCookiebotPluginActivated() ); ?>
</div>
</div>
<div class="row mt-3">
<div class="col-4">
<label class="label-inline">Bing consent category:</label>
</div>
<div class="col-4">
<?php PYS()->render_text_input( 'gdpr_cookiebot_bing_consent_category',
'Enter consent category', ! isCookiebotPluginActivated() ); ?>
</div>
</div>
</div>
</div>
<!-- Cookie Notice -->
<div class="card ">
<div class="card-header">
<?php if ( ! isCookieNoticePluginActivated() ) : ?>
Cookie Notice <span class="text-danger">[not detected]</span><?php cardCollapseBtn(); ?>
<?php else: ?>
Cookie Notice <span class="text-success">[detected]</span><?php cardCollapseBtn(); ?>
<?php endif; ?>
</div>
<div class="card-body">
<div class="row">
<div class="col">
<p>Free plugin with various features, including the option to store negative consent.</p>
<p class="mb-0">Plugin: <a href="https://wordpress.org/plugins/cookie-notice/" target="_blank">https://wordpress.org/plugins/cookie-notice/</a>
</p>
</div>
</div>
<div class="row mt-3">
<div class="col">
<?php PYS()->render_switcher_input( 'gdpr_cookie_notice_integration_enabled', false,
! isCookieNoticePluginActivated() ); ?>
<h4 class="switcher-label">Cookie Notice integration</h4>
</div>
</div>
</div>
</div>
<!-- Cookie Law Info -->
<div class="card">
<div class="card-header">
<?php if ( ! isCookieLawInfoPluginActivated() ) : ?>
GDPR Cookie Consent <span class="text-danger">[not detected]</span><?php cardCollapseBtn(); ?>
<?php else: ?>
GDPR Cookie Consent <span class="text-success">[detected]</span><?php cardCollapseBtn(); ?>
<?php endif; ?>
</div>
<div class="card-body">
<div class="row">
<div class="col">
<p>Free plugin useful features, including the option to store negative consent.</p>
<p class="mb-0">Plugin: <a href="https://wordpress.org/plugins/cookie-law-info/" target="_blank">https://wordpress.org/plugins/cookie-law-info/</a>
</p>
</div>
</div>
<div class="row mt-3">
<div class="col">
<?php PYS()->render_switcher_input( 'gdpr_cookie_law_info_integration_enabled', false,
! isCookieLawInfoPluginActivated() ); ?>
<h4 class="switcher-label">GDPR Cookie Consent integration</h4>
</div>
</div>
</div>
</div>
<!-- Real Cookie Banner -->
<div class="card">
<div class="card-header">
<?php if ( ! isRealCookieBannerPluginActivated() ) : ?>
Real Cookie Banner <span class="text-danger">[not detected]</span><?php cardCollapseBtn(); ?>
<?php else: ?>
Real Cookie Banner <span class="text-success">[detected]</span><?php cardCollapseBtn(); ?>
<?php endif; ?>
</div>
<div class="card-body">
<div class="row">
<div class="col">
<p>Real Cookie Banner is an opt-in cookie and consent management plugin</p>
<p class="mb-0">Plugin: <a href="https://wordpress.org/plugins/real-cookie-banner/" target="_blank">https://wordpress.org/plugins/real-cookie-banner/</a>
</p>
</div>
</div>
<div class="row mt-3">
<div class="col">
<?php PYS()->render_switcher_input( 'gdpr_real_cookie_banner_integration_enabled', false,
! isRealCookieBannerPluginActivated() ); ?>
<h4 class="switcher-label">GDPR Cookie Consent integration</h4>
</div>
</div>
</div>
</div>
<div class="card card-static">
<div class="card-header">
Note
</div>
<div class="card-body">
<div class="row">
<div class="col">
<p>These solutions are not perfect or easy to implement especially for a non-technical person. Contact
THEIR support if you need any help. The free plugins might not cover every aspect of the GDPR
legislation.</p>
<p class="mb-0">We are aware of the shortcomings and we try to offer more easy to use integrations in
the feature.</p>
</div>
</div>
</div>
</div>
<!-- API -->
<div class="card card-static">
<div class="card-header">
For Developers
</div>
<div class="card-body">
<div class="row mb-3">
<div class="col">
<?php PYS()->render_switcher_input( 'gdpr_ajax_enabled' ); ?>
<h4 class="switcher-label">Enable AJAX filter values update</h4>
</div>
</div>
<div class="row">
<div class="col">
<p>Use <code>pys_gdpr_ajax_enabled</code>filter to by-pass option above.</p>
</div>
</div>
<div class="row">
<div class="col">
<p>Use following filters to control each pixel:
<code>pys_disable_by_gdpr</code>, <code>pys_disable_facebook_by_gdpr</code>,
<code>pys_disable_analytics_by_gdpr</code>, <code>pys_disable_google_ads_by_gdpr</code>,
<code>pys_disable_pinterest_by_gdpr</code> or <code>pys_disable_bing_by_gdpr</code>.
</p>
<p class="mb-0">First filter will disable all pixels, other can be used to disable particular pixel.
Simply pass <code>TRUE</code> value to disable a pixel.
</p>
</div>
</div>
</div>
</div>
<hr>
<div class="row justify-content-center">
<div class="col-4">
<button class="btn btn-block btn-save">Save Settings</button>
</div>
</div>

View File

@@ -0,0 +1,40 @@
<?php
namespace PixelYourSite;
if ( ! defined( 'ABSPATH' ) ) {
exit; // Exit if accessed directly.
}
?>
<div class="wrap" id="pys">
<h1><?php _e( 'PixelYourSite', 'pys' ); ?></h1>
<div class="container">
<div class="row">
<div class="col">
<h2 class="section-title">Licenses</h2>
<form method="post" enctype="multipart/form-data">
<?php wp_nonce_field( 'pys_save_settings' ); ?>
<?php foreach ( PYS()->getRegisteredPlugins() as $plugin ) : /** @var Plugin|Settings $plugin */ ?>
<?php if ( $plugin->getSlug() == 'head_footer' ) { continue; } ?>
<div class="card card-static">
<div class="card-header">
<?php esc_html_e( $plugin->getPluginName() ); ?>
</div>
<div class="card-body">
<?php renderLicenseControls( $plugin ); ?>
</div>
</div>
<?php endforeach; ?>
</form>
</div>
</div>
</div>
</div>

View File

@@ -0,0 +1,37 @@
<?php
namespace PixelYourSite;
if ( ! defined( 'ABSPATH' ) ) {
exit; // Exit if accessed directly.
}
if(isset($_GET['clear_logs'])) {
PYS()->getLog()->remove();
$actual_link = (isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] === 'on' ? "https" : "http") . "://$_SERVER[HTTP_HOST]$_SERVER[REQUEST_URI]";
wp_redirect(remove_query_arg( 'clear_logs',$actual_link ));
exit;
}
?>
<div class="card card-static">
<div class="card-header ">
<?php PYS()->render_switcher_input('pys_logs_enable');?> Plugin Logs
<div style="float: right;margin-top: 10px;">
<a style="margin-right: 30px" href="<?php echo esc_url( buildAdminUrl( 'pixelyoursite', 'logs' ) ); ?>&clear_logs=true">Clear Logs</a>
<a href="<?= PYS_Logger::get_log_file_url() ?>" target="_blank" download>Download Logs</a>
</div>
</div>
<div class="card-body">
<textarea style="white-space: nowrap;width: 100%;height: 500px;"><?php
echo PYS()->getLog()->getLogs();
?></textarea>
</div>
</div>
<div class="row justify-content-center">
<div class="col-4">
<button class="btn btn-block btn-sm btn-save">Save Settings</button>
</div>
</div>

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,721 @@
<?php
namespace PixelYourSite;
use PixelYourSite\Events;
if ( ! defined( 'ABSPATH' ) ) {
exit; // Exit if accessed directly.
}
if(isset( $_REQUEST['id'] )) {
$id = sanitize_key($_REQUEST['id']);
$event = CustomEventFactory::getById($id );
} else {
$event = new CustomEvent();
}
$serverUrl = (isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] === 'on' ? "https" : "http") . "://$_SERVER[HTTP_HOST]";
?>
<div class="panel">
<div class="row">
<div class="col">
<div class="d-flex justify-content-between">
<span class="mt-2">With the pro version, you can fire events on clicks, mouse over and page
scroll:</span>
<a target="_blank" class="btn btn-sm btn-primary float-right" href="https://www.pixelyoursite.com/facebook-pixel-plugin/buy-pixelyoursite-pro?utm_source=pixelyoursite-free-plugin&utm_medium=plugin&utm_campaign=free-plugin-upgrade-blue">UPGRADE</a>
</div>
</div>
</div>
</div>
<?php wp_nonce_field( 'pys_update_event' ); ?>
<input type="hidden" name="action" value="update">
<?php Events\renderHiddenInput( $event, 'post_id' ); ?>
<div class="card card-static">
<div class="card-header">
General
</div>
<div class="card-body">
<div class="row mb-3">
<div class="col">
<?php Events\renderSwitcherInput( $event, 'enabled' ); ?>
<h4 class="switcher-label">Enable event</h4>
</div>
</div>
<div class="row">
<div class="col">
<?php Events\renderTextInput( $event, 'title', 'Enter event title' ); ?>
<small class="form-text">For internal use only. Something that will help you remember the event.</small>
</div>
</div>
</div>
</div>
<div class="card card-static">
<div class="card-header">
Event Trigger
</div>
<div class="card-body">
<div class="row mb-3">
<div class="col form-inline">
<label>Fire event when</label>
<?php Events\renderTriggerTypeInput( $event, 'trigger_type' ); ?>
<div class="triger_post_type form-inline" style="display: none">
<?php Events\renderPostTypeSelect( $event, 'post_type_value' ); ?>
</div>
<div class="event-delay form-inline">
<label>with delay</label>
<?php Events\renderNumberInput( $event, 'delay', '0' ); ?>
<label>seconds</label>
</div>
</div>
</div>
<div class="row">
<div class="col form-inline">
<?php Events\renderSwitcherInput( $event, 'enable_time_window',true ); ?>
<label>Fire this event only once in</label>
<?php Events\renderNumberInput( $event, 'time_window', '24' ); ?>
<label>hours</label>
<?php renderProBadge( 'https://www.pixelyoursite.com/?utm_source=pys-free-plugin&utm_medium=pro-badge&utm_campaign=pro-feature' ); ?>
</div>
</div>
<div id="page_visit_panel" class="event_triggers_panel" data-trigger_type="page_visit" style="display: none;">
<div class="row mt-3 event_trigger" data-trigger_id="0" style="display: none;">
<div class="col">
<div class="row">
<div class="col-4">
<select class="form-control-sm" name="" autocomplete="off" style="width: 100%;">
<option value="contains">URL Contains</option>
<option value="match">URL Match</option>
<option value="param_contains" disabled="disabled">URL Parameters Contains (PRO)</option>
<option value="param_match" disabled="disabled">URL Parameters Match (PRO)</option>
</select>
</div>
<div class="col-6">
<input name="" placeholder="Enter URL" class="form-control" type="text">
</div>
<div class="col-2">
<button type="button" class="btn btn-sm remove-row">
<i class="fa fa-trash-o" aria-hidden="true"></i>
</button>
</div>
</div>
</div>
</div>
<?php foreach ( $event->getPageVisitTriggers() as $key => $trigger ) : ?>
<?php $trigger_id = $key + 1; ?>
<div class="row mt-3 event_trigger" data-trigger_id="<?php echo $trigger_id; ?>">
<div class="col">
<div class="row">
<div class="col-4">
<select class="form-control-sm"
name="pys[event][page_visit_triggers][<?php echo $trigger_id; ?>][rule]"
autocomplete="off" style="width: 100%;">
<option value="contains" <?php selected( $trigger['rule'], 'contains' ); ?>>URL Contains</option>
<option value="match" <?php selected( $trigger['rule'], 'match' ); ?>>URL Match</option>
<option value="param_contains" disabled="disabled">URL Parameters Contains (PRO)</option>
<option value="param_match" disabled="disabled">URL Parameters Match (PRO)</option>
</select>
</div>
<div class="col-6">
<input type="text" placeholder="Enter URL" class="form-control"
name="pys[event][page_visit_triggers][<?php echo $trigger_id; ?>][value]"
value="<?php esc_attr_e( $trigger['value'] ); ?>">
</div>
<div class="col-2">
<button type="button" class="btn btn-sm remove-row">
<i class="fa fa-trash-o" aria-hidden="true"></i>
</button>
</div>
</div>
</div>
</div>
<?php endforeach; ?>
<div class="insert-marker"></div>
<div class="row mt-3">
<div class="col-4">
<button class="btn btn-sm btn-block btn-primary add-event-trigger" type="button">Add another
URL</button>
</div>
</div>
</div>
<div id="url_click_panel" class="event_triggers_panel" style="display: none;">
<div class="row mt-3">
<div class="col">
<div class="row">
<div class="col">
<p>This is a PRO trigger. <a
href="https://www.pixelyoursite.com/facebook-pixel-plugin/buy-pixelyoursite-pro?utm_source=pixelyoursite-free-plugin&utm_medium=plugin&utm_campaign=free-plugin-pro-trigger"
target="_blank">Upgrade to get all the benefits</a>.</p>
</div>
</div>
<div class="row">
<div class="col-4">
<?php renderDummySelectInput( 'URL Contains', true ); ?>
</div>
<div class="col-6">
<?php renderDummyTextInput( 'Enter URL' ); ?>
</div>
<div class="col-2">
<button type="button" class="btn btn-sm btn-disabled">
<i class="fa fa-trash-o" aria-hidden="true"></i>
</button>
</div>
</div>
</div>
</div>
<div class="row mt-3 mb-5">
<div class="col-4">
<button class="btn btn-sm btn-block btn-disabled" type="button">Add another
URL</button>
</div>
</div>
</div>
<div id="css_click_panel" class="event_triggers_panel" style="display: none;">
<div class="row mt-3">
<div class="col">
<div class="row">
<div class="col-10">
<?php renderDummyTextInput( 'Enter CSS selector' ); ?>
</div>
<div class="col-2">
<button type="button" class="btn btn-sm btn-disabled">
<i class="fa fa-trash-o" aria-hidden="true"></i>
</button>
</div>
</div>
</div>
</div>
<div class="row mt-3 mb-5">
<div class="col-4">
<button class="btn btn-sm btn-block btn-disabled" type="button">Add another
selector</button>
</div>
</div>
</div>
<div id="css_mouseover_panel" class="event_triggers_panel" style="display: none;">
<div class="row mt-3">
<div class="col">
<div class="row">
<div class="col-10">
<?php renderDummyTextInput( 'Enter CSS selector' ); ?>
</div>
<div class="col-2">
<button type="button" class="btn btn-sm btn-disabled">
<i class="fa fa-trash-o" aria-hidden="true"></i>
</button>
</div>
</div>
</div>
</div>
<div class="row mt-3 mb-5">
<div class="col-4">
<button class="btn btn-sm btn-block btn-disabled" type="button">Add another
selector</button>
</div>
</div>
</div>
<div id="scroll_pos_panel" class="event_triggers_panel" style="display: none;">
<div class="row mt-3">
<div class="col">
<div class="row">
<div class="col-3">
<?php renderDummyNumberInput(); ?>
</div>
<div class="col-2">
<button type="button" class="btn btn-sm btn-disabled">
<i class="fa fa-trash-o" aria-hidden="true"></i>
</button>
</div>
</div>
</div>
</div>
<div class="row mt-3 mb-5">
<div class="col-4">
<button class="btn btn-sm btn-block btn-disabled" type="button">Add another
threshold</button>
</div>
</div>
</div>
<?php $eventsFormFactory = apply_filters("pys_form_event_factory",[]);
foreach ($eventsFormFactory as $activeFormPlugin) : ?>
<div id="<?php echo $activeFormPlugin->getSlug();?>_panel" class="event_triggers_panel" data-trigger_type="<?php echo $activeFormPlugin->getSlug();?>" style="display: none;">
<div class="row mt-3 event_trigger" data-trigger_id="0">
<div class="col">
<?php renderDummySelectInput('Forms');?>
</div>
</div>
<small class="form-text">Select Forms to Trigger the Event.</small>
</div>
<?php
endforeach;
?>
<div id="url_filter_panel" class="event_triggers_panel" style="display: none;">
<div class="row mt-3">
<div class="col">
<div class="row">
<div class="col-10">
<?php renderDummyTextInput( 'Enter URL' ); ?>
</div>
<div class="col-2">
<button type="button" class="btn btn-sm btn-disabled">
<i class="fa fa-trash-o" aria-hidden="true"></i>
</button>
</div>
</div>
</div>
</div>
<div class="row mt-3">
<div class="col-4">
<button class="btn btn-sm btn-block btn-disabled" type="button">Add URL filter</button>
</div>
</div>
</div>
</div>
</div>
<?php if ( Facebook()->enabled() ) : ?>
<div class="card card-static">
<div class="card-header">
Facebook
</div>
<div class="card-body">
<div class="row">
<div class="col">
<?php Events\renderSwitcherInput( $event, 'facebook_enabled' ); ?>
<h4 class="switcher-label">Enable on Facebook</h4>
</div>
</div>
<div id="facebook_panel">
<div class="row mt-3">
<div class="col col-offset-left form-inline">
<label>Event type:</label>
<?php Events\renderFacebookEventTypeInput( $event, 'facebook_event_type' ); ?>
<div class="facebook-custom-event-type form-inline">
<?php Events\renderTextInput( $event, 'facebook_custom_event_type', 'Enter name' ); ?>
</div>
</div>
</div>
<div class="row mt-3">
<div class="col col-offset-left">
<?php Events\renderSwitcherInput( $event, 'facebook_params_enabled' ); ?>
<h4 class="indicator-label">Add Parameters</h4>
</div>
</div>
<div id="facebook_params_panel">
<div class="row mt-3">
<div class="col col-offset-left">
<div class="row mb-3 ViewContent Search AddToCart AddToWishlist InitiateCheckout AddPaymentInfo Purchase Lead CompleteRegistration Subscribe StartTrial">
<label class="col-5 control-label">value</label>
<div class="col-4">
<?php Events\renderFacebookParamInput( $event, 'value' ); ?>
</div>
</div>
<div class="row mb-3 ViewContent Search AddToCart AddToWishlist InitiateCheckout AddPaymentInfo Purchase Lead CompleteRegistration Subscribe StartTrial">
<label class="col-5 control-label">currency</label>
<div class="col-4">
<?php Events\renderCurrencyParamInput( $event, 'currency' ); ?>
</div>
<div class="col-2 facebook-custom-currency">
<?php Events\renderFacebookParamInput( $event, 'custom_currency' ); ?>
</div>
</div>
<div class="row mb-3 ViewContent AddToCart AddToWishlist InitiateCheckout Purchase Lead CompleteRegistration">
<label class="col-5 control-label">content_name</label>
<div class="col-4">
<?php Events\renderFacebookParamInput( $event, 'content_name' ); ?>
</div>
</div>
<div class="row mb-3 ViewContent AddToCart AddToWishlist InitiateCheckout Purchase Lead CompleteRegistration">
<label class="col-5 control-label">content_ids</label>
<div class="col-4">
<?php Events\renderFacebookParamInput( $event, 'content_ids' ); ?>
</div>
</div>
<div class="row mb-3 ViewContent AddToCart InitiateCheckout Purchase">
<label class="col-5 control-label">content_type</label>
<div class="col-4">
<?php Events\renderFacebookParamInput( $event, 'content_type' ); ?>
</div>
</div>
<div class="row mb-3 Search AddToWishlist InitiateCheckout AddPaymentInfo Lead">
<label class="col-5 control-label">content_category</label>
<div class="col-4">
<?php Events\renderFacebookParamInput( $event, 'content_category' ); ?>
</div>
</div>
<div class="row mb-3 InitiateCheckout Purchase">
<label class="col-5 control-label">num_items</label>
<div class="col-4">
<?php Events\renderFacebookParamInput( $event, 'num_items' ); ?>
</div>
</div>
<div class="row mb-3 Purchase">
<label class="col-5 control-label">order_id</label>
<div class="col-4">
<?php Events\renderFacebookParamInput( $event, 'order_id' ); ?>
</div>
</div>
<div class="row mb-3 Search">
<label class="col-5 control-label">search_string</label>
<div class="col-4">
<?php Events\renderFacebookParamInput( $event, 'search_string' ); ?>
</div>
</div>
<div class="row mb-3 CompleteRegistration">
<label class="col-5 control-label">status</label>
<div class="col-4">
<?php Events\renderFacebookParamInput( $event, 'status' ); ?>
</div>
</div>
<div class="row mb-3 Subscribe StartTrial">
<label class="col-5 control-label">predicted_ltv</label>
<div class="col-4">
<?php Events\renderFacebookParamInput( $event, 'predicted_ltv' ); ?>
</div>
</div>
<!-- Custom Facebook Params -->
<div class="row mt-3 facebook-custom-param" data-param_id="0" style="display: none;">
<div class="col-1"></div>
<div class="col-4">
<input name="" placeholder="Enter name" class="form-control custom-param-name" type="text">
</div>
<div class="col-4">
<input name="" placeholder="Enter value" class="form-control custom-param-value"
type="text">
</div>
<div class="col-2">
<button type="button" class="btn btn-sm remove-row">
<i class="fa fa-trash-o" aria-hidden="true"></i>
</button>
</div>
</div>
<?php foreach ( $event->getFacebookCustomParams() as $key => $custom_param ) : ?>
<?php $param_id = $key + 1; ?>
<div class="row mt-3 facebook-custom-param" data-param_id="<?php echo $param_id; ?>">
<div class="col">
<div class="row">
<div class="col-1"></div>
<div class="col-4">
<input type="text" placeholder="Enter name" class="form-control custom-param-name"
name="pys[event][facebook_custom_params][<?php echo $param_id; ?>][name]"
value="<?php esc_attr_e( $custom_param['name'] ); ?>">
</div>
<div class="col-4">
<input type="text" placeholder="Enter value" class="form-control custom-param-value"
name="pys[event][facebook_custom_params][<?php echo $param_id; ?>][value]"
value="<?php esc_attr_e( $custom_param['value'] ); ?>">
</div>
<div class="col-2">
<button type="button" class="btn btn-sm remove-row">
<i class="fa fa-trash-o" aria-hidden="true"></i>
</button>
</div>
</div>
</div>
</div>
<?php endforeach; ?>
<div class="insert-marker"></div>
<div class="row mt-3">
<div class="col-5"></div>
<div class="col-4">
<button class="btn btn-sm btn-block btn-primary add-facebook-parameter" type="button">Add
Custom Parameter</button>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<?php endif; ?>
<?php if ( GA()->enabled() ) : ?>
<div class="card card-static">
<div class="card-header">
Google Analytics
</div>
<div class="card-body">
<div class="row mb-2">
<div class="col">
<?php Events\renderSwitcherInput( $event, 'ga_enabled' ); ?>
<h4 class="switcher-label">Enable on Google Analytics</h4>
</div>
</div>
<div id="analytics_panel">
<div class="row mt-3">
<div class="col ">
<?php
if($event->isGaV4()) :
?>
<div class="row mb-3">
<div class="col col-offset-left form-inline" >
<script>
<?php
$fields = array();
foreach ($event->GAEvents as $group => $items) {
foreach ($items as $name => $elements) {
$fields[] = array("name"=>$name,'fields'=>$elements);
}
}
?>
var ga_fields = <?=json_encode($fields)?>
</script>
<label class=" control-label">Event</label>
<?php Events\renderGoogleAnalyticsV4ActionInput( $event, 'ga_event_action' ); ?>
<div id="ga-custom-action">
<?php Events\renderTextInput( $event, 'ga_custom_event_action', 'Enter name' ); ?>
</div>
</div>
</div>
<div class="ga-param-list">
<?php
foreach($event->getGaParams() as $key=>$val) : ?>
<div class="row mb-3 ga_param">
<label class="col-5 control-label"><?=$key?></label>
<div class="col-4">
<?php Events\renderGAParamInput( $key, $val ); ?>
</div>
</div>
<?php endforeach;?>
</div>
<div class="ga-custom-param-list">
<?php
foreach ( $event->getGACustomParams() as $key => $custom_param ) : ?>
<?php $param_id = $key + 1; ?>
<div class="row mt-3 ga-custom-param" data-param_id="<?php echo $param_id; ?>">
<div class="col">
<div class="row">
<div class="col-1"></div>
<div class="col-4">
<input type="text" placeholder="Enter name" class="form-control custom-param-name"
name="pys[event][ga_custom_params][<?php echo $param_id; ?>][name]"
value="<?php esc_attr_e( $custom_param['name'] ); ?>">
</div>
<div class="col-4">
<input type="text" placeholder="Enter value" class="form-control custom-param-value"
name="pys[event][ga_custom_params][<?php echo $param_id; ?>][value]"
value="<?php esc_attr_e( $custom_param['value'] ); ?>">
</div>
<div class="col-2">
<button type="button" class="btn btn-sm remove-row">
<i class="fa fa-trash-o" aria-hidden="true"></i>
</button>
</div>
</div>
</div>
</div>
<?php endforeach; ?>
</div>
<div class="row mt-3">
<div class="col-5"></div>
<div class="col-4">
<button class="btn btn-sm btn-block btn-primary add-ga-custom-parameter" type="button">Add
Custom Parameter</button>
</div>
</div>
<div class="row mb">
<label class="col-5 control-label">Non-interactive</label>
<div class="col-4">
<?php Events\renderSwitcherInput( $event, 'ga_non_interactive' ); ?>
</div>
</div>
<div class="row mt-3">
<div class="col-12">
The following parameters are automatically tracked: content_name, event_url, post_id, post_type. The paid version tracks the event_hour, event_month, and event_day.
</div>
</div>
<div class="row mt-3 ga_woo_info" style="display: none">
<div class="col-12">
<strong>ATTENTION</strong>: the plugin automatically tracks ecommerce specific events for WooCommerce and Easy Digital Downloads. Make sure you really need this event.
</div>
</div>
<?php else:?>
<div class="row mb-3">
<label class="col-5 control-label">Action</label>
<div class="col-4">
<?php Events\renderGoogleAnalyticsActionInput( $event, 'ga_event_action' ); ?>
</div>
<div class="col-3">
<div id="ga-custom-action">
<?php Events\renderTextInput( $event, 'ga_custom_event_action', 'Enter name' ); ?>
</div>
</div>
</div>
<div class="row mb-3">
<label class="col-5 control-label">Category</label>
<div class="col-4">
<?php Events\renderTextInput( $event, 'ga_event_category' ); ?>
</div>
</div>
<div class="row mb-3">
<label class="col-5 control-label">Label</label>
<div class="col-4">
<?php Events\renderTextInput( $event, 'ga_event_label' ); ?>
</div>
</div>
<div class="row mb-3">
<label class="col-5 control-label">Value</label>
<div class="col-4">
<?php Events\renderTextInput( $event, 'ga_event_value' ); ?>
</div>
</div>
<div class="row mb">
<label class="col-5 control-label">Non-interactive</label>
<div class="col-4">
<?php Events\renderSwitcherInput( $event, 'ga_non_interactive' ); ?>
</div>
</div>
<?php endif?>
</div>
</div>
</div>
</div>
</div>
<?php endif; ?>
<div class="card card-disabled">
<div class="card-header">
Google Ads <?php renderProBadge('https://www.pixelyoursite.com/google-ads-tag/?utm_source=pys-free-plugin&utm_medium=pro-badge&utm_campaign=pro-feature'); ?><?php cardCollapseBtn(); ?>
</div>
<div class="card-body">
<div class="row mb-2">
<div class="col">
<?php renderDummySwitcher(); ?>
<h4 class="switcher-label">Enable on Google Ads</h4>
</div>
</div>
<div class="row mt-3">
<div class="col col-offset-left" id="google_ads_params_panel">
<div class="row mb-3">
<label class="col-5 control-label">Conversion ID</label>
<div class="col-4">
<?php renderDummySelectInput( 'All', true ); ?>
</div>
</div>
<div class="row mb-3">
<label class="col-5 control-label">Conversion Label</label>
<div class="col-4">
<?php renderDummyTextInput( 'Enter name' ); ?>
<small class="form-text">Optional</small>
</div>
</div>
<!-- Default Params -->
<div class="row mb-3">
<label class="col-5 control-label">Action</label>
<div class="col-4">
<?php renderDummySelectInput( 'Custom Action', true ); ?>
</div>
<div class="col-3">
<div id="ga-custom-action">
<?php renderDummyTextInput( 'Enter name' ); ?>
</div>
</div>
</div>
<div class="row mb-3">
<label class="col-5 control-label">Category</label>
<div class="col-4">
<?php renderDummyTextInput(); ?>
</div>
</div>
<div class="row mb-3">
<label class="col-5 control-label">Label</label>
<div class="col-4">
<?php renderDummyTextInput(); ?>
</div>
</div>
<div class="row mb-3">
<label class="col-5 control-label">Value</label>
<div class="col-4">
<?php renderDummyTextInput(); ?>
</div>
</div>
<div class="row mt-3">
<div class="col-5"></div>
<div class="col-4">
<button class="btn btn-sm btn-block btn-secondary" type="button" disabled>Add Custom Parameter
</button>
</div>
</div>
</div>
</div>
</div>
</div>
<?php if ( Pinterest()->enabled() ) : ?>
<?php Pinterest()->renderCustomEventOptions( $event ); ?>
<?php endif; ?>
<?php if ( Bing()->enabled() ) : ?>
<?php Bing()->renderCustomEventOptions( $event ); ?>
<?php endif; ?>
<div class="card card-static card-disabled">
<div class="card-header">
Dynamic Parameters Help <?php renderProBadge(); ?>
</div>
<div class="card-body">
<div class="row">
<div class="col">
<ul class="text-secondary">
<li><code>[id]</code> - it will pull the WordPress post ID</li>
<li><code>[title]</code> - it will pull the content title</li>
<li><code>[content_type]</code> - it will pull the post type (post, product, page and so on)</li>
<li><code>[categories]</code> - it will pull the content categories</li>
<li><code>[tags]</code> - it will pull the content tags</li>
<li><code>[total]</code> - it will pull WooCommerce or EDD order's total when it exists</li>
<li><code>[subtotal]</code> - it will pull WooCommerce or EDD orders's subtotal when it exists</li>
</ul>
<p><strong class="text-secondary">Track URL parameters:</strong></p>
<p class="text-secondary"> Use <code>[url_ParameterName]</code> where ParameterName = the name of the parameter. <br/>
Example:<br/>
This is your URL: <?=$serverUrl?>?ParameterName=123<br/>
The parameter value will be 123.<br/>
</p>
<p class="text-secondary mb-0"><strong>Note:</strong> if a parameter is missing from a particular
page, the event won't include it.</p>
</div>
</div>
</div>
</div>
<hr>
<div class="row justify-content-center">
<div class="col-4">
<button class="btn btn-block btn-save">Save Event</button>
</div>
</div>

View File

@@ -0,0 +1,205 @@
<?php
namespace PixelYourSite;
if ( ! defined( 'ABSPATH' ) ) {
exit; // Exit if accessed directly.
}
$new_event_url = buildAdminUrl( 'pixelyoursite', 'events', 'edit' );
?>
<div class="panel">
<div class="row">
<div class="col">
<div class="d-flex justify-content-between">
<span class="mt-2">With the pro version, you can fire events on clicks, mouse over and page
scroll:</span>
<a target="_blank" class="btn btn-sm btn-primary float-right" href="https://www.pixelyoursite.com/facebook-pixel-plugin/buy-pixelyoursite-pro?utm_source=pixelyoursite-free-plugin&utm_medium=plugin&utm_campaign=free-plugin-upgrade-blue">UPGRADE</a>
</div>
</div>
</div>
</div>
<input type="hidden" name="pys[bulk_event_action_nonce]" value="<?php echo wp_create_nonce( 'bulk_event_action' ); ?>">
<h2 class="section-title">User Defined Events</h2>
<div class="card card-static">
<div class="card-header">
General
</div>
<div class="card-body">
<?php PYS()->render_switcher_input( 'custom_events_enabled' ); ?>
<h4 class="switcher-label">Enable Events</h4>
<div class="mt-3">
<a class="btn btn-sm btn-light btn-events-import">Import Events</a>
<a class="btn ml-3 btn-sm btn-light btn-events-export">Export Events</a>
<a class="ml-3 badge badge-pill badge-pro" href="https://www.pixelyoursite.com/?utm_source=pys-free-plugin&amp;utm_medium=pro-badge&amp;utm_campaign=pro-feature/?utm_source=pys-free-plugin&amp;utm_medium=pro-badge&amp;utm_campaign=pro-feature" target="_blank" >Pro Feature <i class="fa fa-external-link" aria-hidden="true"></i></a>
</div>
</div>
</div>
<div class="card card-static">
<div class="card-header">
Recommeded videos
</div>
<div class="card-body">
<div class="row">
<div class="col">
<p><a href="https://www.youtube.com/watch?v=kEp5BDg7dP0" target="_blank">How to fire EVENTS with PixelYourSite (22:28) - watch now</a></p>
<p><a href="https://www.youtube.com/watch?v=PcXYYGOvahc" target="_blank">Track URL tags as event parameters (8:15) - watch now</a></p>
</div>
</div>
</div>
</div>
<div class="card card-static">
<div class="card-header">
About Parameters
</div>
<div class="card-body">
<div class="row">
<div class="col">
<p>All the events you configure here will automatically get the following parameters for all the tags:
<i>page_title, post_type, post_id, event_URL, user_role, plugin, landing_page (pro), event_time (pro), event_day (pro), event_month (pro), traffic_source (pro), UTMs (pro).</i></p>
<p>Exception: Google Analytics Universal will not get all these parameters. Only <i>event_time (pro), event_day (pro), event_month (pro), traffic_source (pro)</i> are sent as custom dimensions.</p>
<p>You can add other parameters when you configure the events.</p>
</div>
</div>
</div>
</div>
<div class="card card-static">
<div class="card-header">
Events List
</div>
<div class="card-body">
<div class="row mb-3">
<div class="col">
<a href="<?php echo esc_url( $new_event_url ); ?>" class="btn btn-sm btn-primary mr-3">Add</a>
<button class="btn btn-sm btn-light" name="pys[bulk_event_action]" value="enable" type="submit">Enable</button>
<button class="btn btn-sm btn-light" name="pys[bulk_event_action]" value="disable" type="submit">Disable</button>
<button class="btn btn-sm btn-light" name="pys[bulk_event_action]" value="clone" type="submit">Duplicate</button>
<button class="btn btn-sm btn-danger ml-3" name="pys[bulk_event_action]" value="delete" type="submit">Delete</button>
</div>
</div>
<div class="row">
<div class="col">
<table class="table mb-0" id="table-custom-events">
<thead>
<tr>
<th style="width: 45px;">
<label class="custom-control custom-checkbox">
<input type="checkbox" id="pys_select_all_events" value="1" class="custom-control-input">
<span class="custom-control-indicator"></span>
</label>
</th>
<th>Name</th>
<th>Trigger</th>
<th>Networks</th>
</tr>
</thead>
<tbody>
<?php foreach ( CustomEventFactory::get() as $event ) : ?>
<?php
/** @var CustomEvent $event */
$event_edit_url = buildAdminUrl( 'pixelyoursite', 'events', 'edit', array(
'id' => $event->getPostId()
) );
$event_enable_url = buildAdminUrl( 'pixelyoursite', 'events', 'enable', array(
'pys' => array(
'event' => array(
'post_id' => $event->getPostId(),
)
),
'_wpnonce' => wp_create_nonce( 'pys_enable_event' ),
) );
$event_disable_url = buildAdminUrl( 'pixelyoursite', 'events', 'disable', array(
'pys' => array(
'event' => array(
'post_id' => $event->getPostId(),
)
),
'_wpnonce' => wp_create_nonce( 'pys_disable_event' ),
) );
$event_remove_url = buildAdminUrl( 'pixelyoursite', 'events', 'remove', array(
'pys' => array(
'event' => array(
'post_id' => $event->getPostId(),
)
),
'_wpnonce' => wp_create_nonce( 'pys_remove_event' ),
) );
?>
<tr data-post_id="<?php esc_attr_e( $event->getPostId() ); ?>"
class="<?php echo $event->isEnabled() ? '' : 'disabled'; ?>">
<td>
<label class="custom-control custom-checkbox">
<input type="checkbox" name="pys[selected_events][]"
value="<?php esc_attr_e( $event->getPostId() ); ?>"
class="custom-control-input pys-select-event">
<span class="custom-control-indicator"></span>
</label>
</td>
<td>
<a href="<?php echo esc_url( $event_edit_url ); ?>"><?php esc_html_e( $event->getTitle() ); ?></a>
<span class="event-actions">
<?php if ( $event->isEnabled() ) : ?>
<a href="<?php echo esc_url( $event_disable_url ); ?>">Disable</a>
<?php else : ?>
<a href="<?php echo esc_url( $event_enable_url ); ?>">Enable</a>
<?php endif; ?>
&nbsp;|&nbsp;
<a href="<?php echo esc_url( $event_remove_url ); ?>" class="
text-danger">Remove</a>
</span>
</td>
<td>Page Visit</td>
<td class="networks">
<?php if ( Facebook()->enabled() && $event->isFacebookEnabled() ) : ?>
<i class="fa fa-facebook-square"></i>
<?php else : ?>
<i class="fa fa-facebook-square" style="opacity: .25;"></i>
<?php endif; ?>
<?php if ( GA()->enabled() && $event->isGoogleAnalyticsEnabled() ) : ?>
<i class="fa fa-area-chart"></i>
<?php else : ?>
<i class="fa fa-area-chart" style="opacity: .25;"></i>
<?php endif; ?>
<i class="fa fa-google" style="opacity: .25;"></i>
<?php if ( Pinterest()->enabled() && $event->isPinterestEnabled() ) : ?>
<i class="fa fa-pinterest-square"></i>
<?php else : ?>
<i class="fa fa-pinterest-square" style="opacity: .25;"></i>
<?php endif; ?>
</td>
</tr>
<?php endforeach; ?>
</tbody>
</table>
</div>
</div>
</div>
</div>
<hr>
<div class="row justify-content-center">
<div class="col-4">
<button class="btn btn-block btn-save">Save Settings</button>
</div>
</div>

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,359 @@
<?php
namespace PixelYourSite;
use Cartflows_Helper;
if ( ! defined( 'ABSPATH' ) ) {
exit; // Exit if accessed directly.
}
?>
<h2 class="section-title">CartFlows Settings</h2>
<!-- Enable CartFlows -->
<div class="card card-static">
<div class="card-header">
General
</div>
<div class="card-body">
<div class="row">
<div class="col">
<p>From here you can control the events and parameters fired by PixelYourSite Professional on CartFlos pages and actions.</p>
<p>To learn more <a href="https://www.pixelyoursite.com/cartflows-and-pixelyoursite" target="_blank">go to this dedicated page and watch the video</a></p>
<?php PYS()->render_switcher_input( "",false,true ); ?>
<h4 class="switcher-label">Enable CartFlows set-up</h4>
<?php renderProBadge(); ?>
</div>
</div>
</div>
</div>
<!-- Dedicated Tracking -->
<div class="card ">
<div class="card-header">
Dedicated Tracking IDs (optional) <?php renderProBadge(); cardCollapseBtn(); ?>
</div>
<div class="card-body">
<?php if ( Facebook()->enabled() ) : ?>
<div class="plate">
<div class="row pt-3">
<div class="col">
<h4 class="mb-3">Meta Pixel (formerly Facebook Pixel)</h4>
<h4 class="label">Meta Pixel (formerly Facebook Pixel) ID:</h4>
<?php Facebook()->render_text_input( 'wcf_pixel_id', 'Add your pixel ID there',true ); ?>
</div>
</div>
<div class="row mt-3">
<div class="col">
<h4 class="label">Conversion API:</h4>
<?php Facebook()->render_text_area_input( 'wcf_server_access_api_token', 'Add your token there',true ); ?>
</div>
</div>
<div class="row mt-3">
<div class="col">
<h4 class="label">test_event_code:</h4>
<?php Facebook()->render_text_input( 'wcf_test_api_event_code', 'Add your test_event_code there',true ); ?>
</div>
</div>
<div class="row mt-3 pb-3">
<div class="col">
<h4 class="label">Verify your domain:</h4>
<?php Facebook()->render_text_input( 'wcf_verify_meta_tag', 'Add the verification meta-tag there' ,true); ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if ( GA()->enabled() ) : ?>
<hr>
<div class="plate">
<div class="row pt-3 mt-3 pb-3">
<div class="col">
<h4 class="mb-3">Google Analytics</h4>
<h4 class="label">Google Analytics ID:</h4>
<?php GA()->render_text_input( 'wcf_pixel_id', 'Add your ID there',true ); ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if ( Bing()->enabled() ) : ?>
<hr>
<div class="plate">
<div class="row pt-3 mt-3 pb-3">
<div class="col">
<h4 class="mb-3">Bing Tag</h4>
<h4 class="label">Bing Tag ID:</h4>
<?php Bing()->render_text_input( 'wcf_pixel_id', 'Add your ID there',true ); ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if ( Pinterest()->enabled() ) : ?>
<hr>
<div class="plate">
<div class="row pt-3 mt-3">
<div class="col">
<h4 class="mb-3">Pinterest Pixel</h4>
<h4 class="label">Pinterest Pixel ID:</h4>
<?php Pinterest()->render_text_input( 'wcf_pixel_id', 'Add your ID there',true ); ?>
</div>
</div>
<div class="row mt-3 pb-3">
<div class="col">
<h4 class="label">Verify your domain:</h4>
<?php Pinterest()->render_text_input( 'wcf_verify_meta_tag', 'Add the verification meta-tag there',true ); ?>
</div>
</div>
</div>
<?php endif; ?>
</div>
</div>
<h2 class="section-title">Standard Events Settings</h2>
<!-- Purchase -->
<div class="card ">
<div class="card-header">
Purchase settings <?php renderProBadge(); cardCollapseBtn(); ?>
</div>
<div class="card-body">
<div class="row">
<div class="col">
<p>You have additional options for this event on the plugins WooCommerce page</p>
<div class="custom-controls-stacked mb-3">
<?php PYS()->render_radio_input( 'wcf_purchase_on', 'all', 'Fire a Purchase event for each Upsale and Downsale step',true ); ?>
<?php PYS()->render_radio_input( 'wcf_purchase_on', 'last', 'Fire a single Purchase event for all Upsale or Downsale steps. <strong>Caution</strong>: if the client abandons a step, we wont\'t track the transaction ' ,true ); ?>
</div>
<?php PYS()->render_switcher_input( 'wcf_purchase_on_optin_enabled',false,true ); ?>
<h4 class="switcher-label">Fire the event Optin offers</h4>
</div>
</div>
</div>
</div>
<!-- AddToCart -->
<div class="card ">
<div class="card-header">
AddToCart settings <?php renderProBadge(); cardCollapseBtn(); ?>
</div>
<div class="card-body">
<div class="row">
<div class="col">
<p>You have additional options for this event on the plugins WooCommerce page</p>
<?php PYS()->render_switcher_input( 'wcf_add_to_cart_on_bump_click_enabled',false,true ); ?>
<h4 class="switcher-label">Fire the event for order bumps</h4>
</div>
</div>
</div>
</div>
<!-- Lead -->
<div class="card ">
<div class="card-header has_switch">
<?php PYS()->render_switcher_input( 'wcf_lead_enabled',false,true ); ?> Lead <?php renderProBadge(); cardCollapseBtn(); ?>
</div>
<div class="card-body">
<div class="row">
<div class="col">
Fire a Lead event when a Optin offer is accepted
</div>
</div>
</div>
</div>
<!-- ViewContent -->
<div class="card ">
<div class="card-header">
ViewContent settings <?php renderProBadge(); cardCollapseBtn(); ?>
</div>
<div class="card-body">
<div class="row">
<div class="col">
<p>You have additional options for this event on the plugins WooCommerce page</p>
<p>The event is always fired on page</p>
<?php PYS()->render_switcher_input( 'wcf_sell_step_view_content_enabled' ,false,true ); ?>
<h4 class="switcher-label">Fire the event on Upsale and Downsale steps</h4>
</div>
</div>
</div>
</div>
<h2 class="section-title">Custom Events</h2>
<!-- CartFlows -->
<div class="card ">
<div class="card-header has_switch">
<?php PYS()->render_switcher_input( 'wcf_cart_flows_event_enabled',false,true ); ?> CartFlows Event <?php renderProBadge(); cardCollapseBtn(); ?>
</div>
<div class="card-body">
<?php if ( Facebook()->enabled() ) : ?>
<div class="row">
<div class="col">
<p>Fire this event for all CartFlows pages.</p>
<?php Facebook()->render_switcher_input( 'wcf_cart_flows_event_enabled',false,true ); ?>
<h4 class="switcher-label">Facebook</h4>
</div>
</div>
<?php endif; ?>
<?php if ( GA()->enabled() ) : ?>
<div class="row">
<div class="col">
<?php GA()->render_switcher_input( 'wcf_cart_flows_event_enabled',false,true ); ?>
<h4 class="switcher-label">Google Analytics</h4>
</div>
</div>
<?php endif; ?>
<?php if ( Pinterest()->enabled() ) : ?>
<div class="row">
<div class="col">
<?php Pinterest()->render_switcher_input( 'wcf_cart_flows_event_enabled',false,true ); ?>
<h4 class="switcher-label">Pinterest</h4>
</div>
</div>
<?php endif; ?>
<?php if ( Bing()->enabled() ) : ?>
<div class="row">
<div class="col">
<?php Bing()->render_switcher_input( 'wcf_cart_flows_event_enabled',false,true ); ?>
<h4 class="switcher-label">Bing</h4>
</div>
</div>
<?php endif; ?>
</div>
</div>
<!-- step event -->
<div class="card ">
<div class="card-header has_switch">
<?php PYS()->render_switcher_input( 'wcf_step_event_enabled',false,true ); ?> Track Steps <?php renderProBadge(); cardCollapseBtn(); ?>
</div>
<div class="card-body">
<?php if ( Facebook()->enabled() ) : ?>
<div class="row">
<div class="col">
<p>Fire CartFlows_Landing, CartFlows_Upsale, CartFlows_Downsale, CartFlows_Checkout, CartFlows_ThankYou,CartFlows_Optin</p>
<?php Facebook()->render_switcher_input( 'wcf_step_event_enabled',false,true ); ?>
<h4 class="switcher-label">Facebook</h4>
</div>
</div>
<?php endif; ?>
<?php if ( GA()->enabled() ) : ?>
<div class="row">
<div class="col">
<?php GA()->render_switcher_input( 'wcf_step_event_enabled',false,true ); ?>
<h4 class="switcher-label">Google Analytics</h4>
</div>
</div>
<?php endif; ?>
<?php if ( Pinterest()->enabled() ) : ?>
<div class="row">
<div class="col">
<?php Pinterest()->render_switcher_input( 'wcf_step_event_enabled',false,true ); ?>
<h4 class="switcher-label">Pinterest</h4>
</div>
</div>
<?php endif; ?>
<?php if ( Bing()->enabled() ) : ?>
<div class="row">
<div class="col">
<?php Bing()->render_switcher_input( 'wcf_step_event_enabled',false,true ); ?>
<h4 class="switcher-label">Bing</h4>
</div>
</div>
<?php endif; ?>
</div>
</div>
<!-- step event -->
<div class="card ">
<div class="card-header has_switch">
<?php PYS()->render_switcher_input( 'wcf_bump_event_enabled',false,true ); ?> Track Order Bumps <?php renderProBadge(); cardCollapseBtn(); ?>
</div>
<div class="card-body">
<?php if ( Facebook()->enabled() ) : ?>
<div class="row">
<div class="col">
<p>Fire CartFlows_order_bump, when an order bump is accepted</p>
<?php Facebook()->render_switcher_input( 'wcf_bump_event_enabled',false,true ); ?>
<h4 class="switcher-label">Facebook</h4>
</div>
</div>
<?php endif; ?>
<?php if ( GA()->enabled() ) : ?>
<div class="row">
<div class="col">
<?php GA()->render_switcher_input( 'wcf_bump_event_enabled',false,true ); ?>
<h4 class="switcher-label">Google Analytics</h4>
</div>
</div>
<?php endif; ?>
<?php if ( Pinterest()->enabled() ) : ?>
<div class="row">
<div class="col">
<?php Pinterest()->render_switcher_input( 'wcf_bump_event_enabled',false,true ); ?>
<h4 class="switcher-label">Pinterest</h4>
</div>
</div>
<?php endif; ?>
<?php if ( Bing()->enabled() ) : ?>
<div class="row">
<div class="col">
<?php Bing()->render_switcher_input( 'wcf_bump_event_enabled',false,true ); ?>
<h4 class="switcher-label">Bing</h4>
</div>
</div>
<?php endif; ?>
</div>
</div>
<h2 class="section-title">CartFlows Events Parameters</h2>
<div class="card ">
<div class="card-header">
Control the CartFlows Parameters <?php renderProBadge(); cardCollapseBtn(); ?>
</div>
<div class="card-body">
<div class="row">
<div class="col">
<?php PYS()->render_switcher_input( 'wcf_global_cartflows_parameter_enabled',false,true ); ?>
<h4 class="switcher-label">CartFlows</h4>
</div>
</div>
<div class="row">
<div class="col">
<?php PYS()->render_switcher_input( 'wcf_global_cartflows_flow_parameter_enabled',false,true ); ?>
<h4 class="switcher-label">CartFlows_flow</h4>
</div>
</div>
<div class="row">
<div class="col">
<?php PYS()->render_switcher_input( 'wcf_global_cartflows_step_parameter_enabled',false,true ); ?>
<h4 class="switcher-label">CartFlows_step</h4>
</div>
</div>
</div>
</div>
<div class="row justify-content-center">
<div class="col-4">
<button class="btn btn-block btn-sm btn-save">Save Settings</button>
</div>
</div>

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,579 @@
<!-- GENERAL -->
<div id="pys-general_event" style="display: none; visibility: hidden">
<p>The GeneralEvent will track the following parameters:</p>
<ul>
<li>content_name</li>
<li>content_category</li>
<li>tag</li>
<li>post_type</li>
<li>post_id</li>
<li>domain</li>
<li>user's role</li>
<li>domain</li>
<li>plugin's name</li>
<li>
<del>traffic_source</del>
(<a href="https://www.pixelyoursite.com/?utm_source=pixelyoursite-free-plugin&utm_medium=plugin&utm_campaign=free-plugin-info-popup">pro</a>)
</li>
<li>
<del>UTMs</del>
(<a href="https://www.pixelyoursite.com/?utm_source=pixelyoursite-free-plugin&utm_medium=plugin&utm_campaign=free-plugin-info-popup">pro</a>)
</li>
<li>
<del>Visitor's browser's time (hour, day, month)</del>
(<a href="https://www.pixelyoursite.com/?utm_source=pixelyoursite-free-plugin&utm_medium=plugin&utm_campaign=free-plugin-info-popup">pro</a>)
</li>
</ul>
<p>Use it to create Custom Audiences, Custom Conversions, or for Facebook Analytics.</p>
</div>
<div id="pys-search_event" style="display: none; visibility: hidden">
<p>On Facebook and Pinterest, the event will send these parameters:</p>
<ul>
<li>search_string: the exact searched word or phrase</li>
<li>content_name</li>
<li>content_category</li>
<li>tag</li>
<li>post_type</li>
<li>post_id</li>
<li>domain</li>
<li>user's role</li>
<li>domain name</li>
<li>plugin's name</li>
<li>
<del>traffic_source</del>
(<a href="https://www.pixelyoursite.com/?utm_source=pixelyoursite-free-plugin&utm_medium=plugin&utm_campaign=free-plugin-info-popup">pro</a>)
</li>
<li>
<del>UTMs</del>
(<a href="https://www.pixelyoursite.com/?utm_source=pixelyoursite-free-plugin&utm_medium=plugin&utm_campaign=free-plugin-info-popup">pro</a>)
</li>
<li>
<del>Visitor's browser's time (hour, day, month)</del>
(<a href="https://www.pixelyoursite.com/?utm_source=pixelyoursite-free-plugin&utm_medium=plugin&utm_campaign=free-plugin-info-popup">pro</a>)
</li>
</ul>
<p>On Google Analytics, the event will have the following structure:</p>
<ul>
<li>Event Category: WordPress Search or WooCommerce Search</li>
<li>Event Action: search</li>
<li>Event Label: the search string</li>
</ul>
</div>
<div id="pys-click_event" style="display: none; visibility: hidden">
<p>The ClickEvent will have the following parameters on Facebook and Pinterest:</p>
<ul>
<li>tag_text: the links text</li>
<li>tag_type: a (for HTML links) or button</li>
<li>content_name</li>
<li>content_category</li>
<li>tag</li>
<li>post_type</li>
<li>post_id</li>
<li>domain</li>
<li>traffic_source</li>
<li>UTMs</li>
<li>Visitor's browser's time (hour, day, month)</li>
<li>user's role</li>
<li>domain name</li>
<li>plugin's name</li>
</ul>
<p>Use it to create specific Custom Audiences or Custom Conversions.</p>
<p>On Google Analytics the event will have the following structure:</p>
<ul>
<li>Event Category: ClickEvent</li>
<li>Event Action: the URL link</li>
<li>Event Label: the link or button text</li>
</ul>
</div>
<div id="pys-watch_video_event" style="display: none; visibility: hidden">
<p>The event will have 5 separate triggers:</p>
<ul>
<li>play - when the video starts</li>
<li>10%</li>
<li>50%</li>
<li>90%</li>
<li>100%</li>
</ul>
<p>On Facebook and Pinterest it will have the following parameters:</p>
<ul>
<li>event_trigger: it can be play, 10%, 50%, 90% or 100%</li>
<li>video_title</li>
<li>video_id</li>
<li>content_name</li>
<li>content_category</li>
<li>tag</li>
<li>post_type</li>
<li>post_id</li>
<li>traffic_source</li>
<li>UTMs</li>
<li>Visitor's browser's time (hour, day, month)</li>
<li>user's role</li>
<li>domain name</li>
<li>plugin's name</li>
</ul>
<p>On Google Analytics it will have:</p>
<ul>
<li>Event Category: WatchVideo</li>
<li>Event Action: play, 10%, 50%, 90%, 100%</li>
<li>Event Label: the video title</li>
</ul>
</div>
<div id="pys-complete_registration_event" style="display: none; visibility: hidden">
<p>On Facebook and Pinterest the event will have the following parameters:</p>
<ul>
<li>traffic_source</li>
<li>UTMs</li>
<li>Visitor's browser's time (hour, day, month)</li>
<li>user's role</li>
<li>domain name</li>
<li>plugin's name</li>
</ul>
<p>On Google Analytics it will have this structure:</p>
<ul>
<li>Event Category: engagement</li>
<li>Event Action: sign_up</li>
<li>Event Label: user's role</li>
</ul>
</div>
<div id="pys-form_event" style="display: none; visibility: hidden">
<p>This event will have the following parameters on Facebook and Pinterest:</p>
<ul>
<li>form_class: the CSS class identifying the form</li>
<li>content_name</li>
<li>content_category</li>
<li>tag</li>
<li>post_type</li>
<li>post_id</li>
<li>traffic_source</li>
<li>UTMs</li>
<li>Visitor's browser's time (hour, day, month)</li>
<li>user's role</li>
<li>domain name</li>
<li>plugin's name</li>
</ul>
<p>On Google Analytics it will have the following structure:</p>
<ul>
<li>Event Category: Form</li>
<li>Event Action: the form page URL</li>
<li>Event Label: the CSS class identifying the form</li>
</ul>
</div>
<div id="pys-comment_event" style="display: none; visibility: hidden">
<p>On Facebook and Pinterest, the event will have the following parameters:</p>
<ul>
<li>content_name</li>
<li>content_category</li>
<li>tag</li>
<li>post_type</li>
<li>post_id</li>
<li>user's role</li>
<li>domain name</li>
<li>plugin's name</li>
<li>
<del>traffic_source</del>
(<a href="https://www.pixelyoursite.com/?utm_source=pixelyoursite-free-plugin&utm_medium=plugin&utm_campaign=free-plugin-info-popup">pro</a>)
</li>
<li>
<del>UTMs</del>
(<a href="https://www.pixelyoursite.com/?utm_source=pixelyoursite-free-plugin&utm_medium=plugin&utm_campaign=free-plugin-info-popup">pro</a>)
</li>
<li>
<del>Visitor's browser's time (hour, day, month)</del>
(<a href="https://www.pixelyoursite.com/?utm_source=pixelyoursite-free-plugin&utm_medium=plugin&utm_campaign=free-plugin-info-popup">pro</a>)
</li>
</ul>
<p>On Google Analytics, the event will have this structure:</p>
<ul>
<li>Event Category: Comment</li>
<li>Event Action: the URL where the comment was posted</li>
<li>Event Label: the page title</li>
</ul>
</div>
<div id="pys-download_docs_event" style="display: none; visibility: hidden">
<p>This event will have the following parameters on Facebook and Pinterest:</p>
<ul>
<li>download_name: the name of the downloaded file</li>
<li>download_type: the file format (jpg, png, zip, and so on)</li>
<li>download_url: the exact URL of the downloaded file</li>
<li>content_name</li>
<li>content_category</li>
<li>tag</li>
<li>post_type</li>
<li>post_id</li>
<li>user's role</li>
<li>domain name</li>
<li>plugin's name</li>
<li>
<del>traffic_source</del>
(<a href="https://www.pixelyoursite.com/?utm_source=pixelyoursite-free-plugin&utm_medium=plugin&utm_campaign=free-plugin-info-popup">pro</a>)
</li>
<li>
<del>UTMs</del>
(<a href="https://www.pixelyoursite.com/?utm_source=pixelyoursite-free-plugin&utm_medium=plugin&utm_campaign=free-plugin-info-popup">pro</a>)
</li>
<li>
<del>Visitor's browser's time (hour, day, month)</del>
(<a href="https://www.pixelyoursite.com/?utm_source=pixelyoursite-free-plugin&utm_medium=plugin&utm_campaign=free-plugin-info-popup">pro</a>)
</li>
</ul>
<p>On Google Analytics it will have the next structure:</p>
<ul>
<li>Event Category: Download</li>
<li>Event Action: the downloaded file URL</li>
<li>Event Label: the downloaded file name</li>
</ul>
</div>
<div id="pys-adsense_event" style="display: none; visibility: hidden">
<p>This event will have the following parameters on Facebook and Pinterest:</p>
<ul>
<li>content_name</li>
<li>content_category</li>
<li>tag</li>
<li>post_type</li>
<li>post_id</li>
<li>traffic_source</li>
<li>UTMs</li>
<li>Visitor's browser's time (hour, day, month)</li>
<li>user's role</li>
<li>domain name</li>
<li>plugin's name</li>
</ul>
</div>
<!-- WOOCOMMERCE -->
<div id="pys-woo_facebook_am_params" style="display: none; visibility: hidden">
<p>All the e-commerce events are Dynamic Product Ads ready, having the two required parameters:</p>
<ul>
<li>content_type: product or product group</li>
<li>content_ids</li>
</ul>
<p>The following events are used for Dynamic Product Ads:</p>
<ul>
<li>ViewContent: on single product pages</li>
<li>ViewCategory: on WooCommerce category pages</li>
<li>AddToCart: when a product is added to cart</li>
<li>Purchase: when a transaction is completed</li>
</ul>
<p><strong>IMPORTANT:</strong> in order to run Dynamic Product ads you need a Product Catalog. You can create one
using our <a href="https://www.pixelyoursite.com/product-catalog-facebook?utm_source=pixelyoursite-free-plugin&utm_medium=plugin&utm_campaign=free-plugin-info-popup" target="_blank">dedicated
Product Catalog Feed plugin</a>.</p>
</div>
<div id="pys-woo_facebook_and_pinterest_params" style="display: none; visibility: hidden">
<p>Your WooCommerce events track a large number of parameters that you can use for Custom Audiences, Custom
Conversions, or inside Facebook Analytics.</p>
<ul>
<li>content_name: the name of the products</li>
<li>category_name: the product categories</li>
<li>tags: the product tags</li>
<li>num_items: the number of products in the cart</li>
<li>value: the event value</li>
<li>currency: your store currency</li>
<li>product_price: the price of the product</li>
<li>user_role: the type of user firing the event</li>
<li>domain: the domain name</li>
</ul>
</div>
<div id="pys-woo_facebook_and_pinterest_pro_params" style="display: none; visibility: hidden">
<p>The PRO version will track even more parameters, helping you to create even more Custom Conversions or Audiences.
The browser's time-related parameters will help you understand when your clients convert (their time).</p>
<ul>
<li>traffic_source</li>
<li>UTMs: the UTMs of the landing URL</li>
<li>month: the transaction's month, based on the visitor's browser's time</li>
<li>day: the transaction's day, based on the visitor's browser's time</li>
<li>hour: the hour interval, based on the visitor's browser's time</li>
</ul>
</div>
<div id="pys-woo_facebook_and_pinterest_purchase_params" style="display: none; visibility: hidden">
<p>Your Purchase event tracks important parameters. They can be used for Custom Audiences or Conversions.</p>
<ul>
<li>content_type: product</li>
<li>content_ids: the ids of the purchased events</li>
<li>value: the event value, as configured inside the plugin</li>
<li>currency: transaction's currency</li>
<li>transactions_count: the number of transactions made by the same client</li>
<li>content_name: the product's numbers</li>
<li>category_name: the products categories</li>
<li>num_items: the number of products</li>
<li>plugin: PixelYourSite</li>
<li>domain: your domain name</li>
<li>user_roles: the client user role</li>
<li>contents: A list of JSON object that contains the product IDs associated with the event as well as
additional information about the products
</li>
</ul>
</div>
<div id="pys-woo_facebook_and_pinterest_purchase_pro_params" style="display: none; visibility: hidden">
<p>The <a href="https://www.pixelyoursite.com/?utm_source=pixelyoursite-free-plugin&utm_medium=plugin&utm_campaign=free-plugin-info-popup">PRO version</a> Purchase event will track an extraordinary number of
extra useful parameters. Use them for your super-focus Custom Audiences or Custom Conversions, and for Facebook
Analytics reports.</p>
<ul>
<li>total: the transaction's total</li>
<li>lifetime_value: the client lifetime's value</li>
<li>average_order: the average order of the transactions made by the same client</li>
<li>payment: payment type</li>
<li>tax: the tax value</li>
<li>shipping: shipping option</li>
<li>shipping_cost: the shipping cost</li>
<li>coupon_used: use of coupons (yes/no)</li>
<li>coupon_name: the name of the coupon used</li>
<li>content_name: the product's numbers</li>
<li>order_id: the order's id</li>
<li>hour: the transaction's hour interval, based on the client's browser's time</li>
<li>day: the transaction's day, based on the client's browser's time</li>
<li>month: the transaction's month, based on the client's browser's time</li>
<li>traffic_source: direct</li>
<li>UTMs: the UMTs of the landing URL</li>
</ul>
</div>
<div id="pys-woo_ga_enhanced_ecommerce_params" style="display: none; visibility: hidden">
<p>In-depth e-commerce data will be sent to Google Analytics, like transaction value, tax, shipping, products, and
product categories. Product views, add to cart, remove from cart, checkout, and purchases are tracked
automatically and you can analyze and compare the stats inside Google Analytics E-commerce reports.</p>
</div>
<div id="pys-woo_google_ads_enhanced_ecommerce_params" style="display: none; visibility: hidden">
<p>The <a href="https://www.pixelyoursite.com/?utm_source=pixelyoursite-free-plugin&utm_medium=plugin&utm_campaign=free-plugin-info-popup">pro version</a> implements the Google Ads tag (former AdWords). All
the e-commerce events will be sent to Google Ads. These events can be used for audiences. You can also configure
"conversions" to track your transactions. The e-commerce events will be Dynamic Remarketing ready. You can
select between the "Retail" or "Custom" vertical, according to your needs.</p>
</div>
<div id="pys-woo_purchase_on_transaction" style="display: none; visibility: hidden">
<p>This will make sure that simple page refreshes or reloads won't affect your stats. Disable this option if you
plan to test the event.</p>
</div>
<div id="pys-woo_purchase_event_value" style="display: none; visibility: hidden">
<p><strong>Value is mandatory for this event.</strong></p>
<p>Your Purchase event value for your business might not be the exact value of the products or services, because you
have all sorts of costs included. You can use the order total, a percent of the total, or a fixed value.</p>
<p>We also added a "total" parameter for this event that will always reflect the full value of each purchase.</p>
<p>Note: Some experts think that Facebook will better optimize your ads when conversion value is smaller, making
sure that you don't overspend. It's a controversial theory, but one you can test yourself.</p>
</div>
<div id="pys-woo_initiate_checkout_event_value" style="display: none; visibility: hidden">
<p>Value is not mandatory for this event. If you want, you can enable and configure it to reflect the value this
event has for your business.</p>
</div>
<div id="pys-woo_add_to_cart_event_value" style="display: none; visibility: hidden">
<p>Value is not mandatory for this event. If you want, you can enable and configure it to reflect the value this
event has for your business.</p>
</div>
<div id="pys-woo_view_content_event_value" style="display: none; visibility: hidden">
<p>Value is not mandatory for this event. If you want, you can enable and configure it to reflect the value this
event has for your business.</p>
</div>
<div id="pys-woo_affiliate_event_value" style="display: none; visibility: hidden">
<p>Value is not mandatory for this event. If you want, you can enable and configure it to reflect the value this
event has for your business.</p>
</div>
<div id="pys-woo_paypal_event_value" style="display: none; visibility: hidden">
<p>Value is not mandatory for this event. If you want, you can enable and configure it to reflect the value this
event has for your business.</p>
</div>
<!-- EDD -->
<div id="pys-edd_facebook_am_params" style="display: none; visibility: hidden">
<p>All the e-commerce events are Dynamic Product Ads ready, having the two required parameters:</p>
<ul>
<li>content_type: product or product group</li>
<li>content_ids</li>
</ul>
<p>The following events are used for Dynamic Product Ads:</p>
<ul>
<li>ViewContent: on single product pages</li>
<li>ViewCategory: on WooCommerce category pages</li>
<li>AddToCart: when a product is added to cart</li>
<li>Purchase: when a transaction is completed</li>
</ul>
<p><strong>IMPORTANT:</strong> in order to run Dynamic Product ads you need a Product Catalog. You can create one
using our <a href="https://www.pixelyoursite.com/easy-digital-downloads-product-catalog?utm_source=pixelyoursite-free-plugin&utm_medium=plugin&utm_campaign=free-plugin-info-popup"
target="_blank">dedicated
Product Catalog Feed plugin</a>.</p>
</div>
<div id="pys-edd_facebook_and_pinterest_params" style="display: none; visibility: hidden">
<p>Your Easy Digital Downloads events track a large number of parameters that you can use for Custom Audiences, Custom
Conversions, or inside Facebook Analytics.</p>
<ul>
<li>content_name: the name of the products</li>
<li>category_name: the product categories</li>
<li>tags: the product tags</li>
<li>num_items: the number of products in the cart</li>
<li>value: the event value</li>
<li>currency: your store currency</li>
<li>product_price: the price of the product</li>
<li>user_role: the type of user firing the event</li>
<li>domain: the domain name</li>
</ul>
</div>
<div id="pys-edd_facebook_and_pinterest_pro_params" style="display: none; visibility: hidden">
<p>The PRO version will track even more parameters, helping you to create even more Custom Conversions or Audiences.
The browser's time-related parameters will help you understand when your clients convert (their time).</p>
<ul>
<li>traffic_source</li>
<li>UTMs: the UTMs of the landing URL</li>
<li>month: the transaction's month, based on the visitor's browser's time</li>
<li>day: the transaction's day, based on the visitor's browser's time</li>
<li>hour: the hour interval, based on the visitor's browser's time</li>
</ul>
</div>
<div id="pys-edd_facebook_and_pinterest_purchase_params" style="display: none; visibility: hidden">
<p>Your Purchase event tracks important parameters. They can be used for Custom Audiences or Conversions.</p>
<ul>
<li>content_type: product</li>
<li>content_ids: the ids of the purchased events</li>
<li>value: the event value, as configured inside the plugin</li>
<li>currency: transaction's currency</li>
<li>content_name: the product's numbers</li>
<li>category_name: the products categories</li>
<li>num_items: the number of products</li>
<li>plugin: PixelYourSite</li>
<li>domain: your domain name</li>
<li>user_roles: the client user role</li>
<li>contents: A list of JSON object that contains the product IDs associated with the event as well as
additional information about the products
</li>
</ul>
</div>
<div id="pys-edd_facebook_and_pinterest_purchase_pro_params" style="display: none; visibility: hidden">
<p>The <a href="https://www.pixelyoursite.com/?utm_source=pixelyoursite-free-plugin&utm_medium=plugin&utm_campaign=free-plugin-info-popup">PRO version</a> Purchase event will track an extraordinary number of
extra useful parameters. Use them for your super-focus Custom Audiences or Custom Conversions, and for Facebook
Analytics reports.</p>
<ul>
<li>total: the transaction's total</li>
<li>lifetime_value: the client lifetime's value</li>
<li>average_order: the average order of the transactions made by the same client</li>
<li>payment: payment type</li>
<li>tax: the tax value</li>
<li>shipping: shipping option</li>
<li>shipping_cost: the shipping cost</li>
<li>coupon_used: use of coupons (yes/no)</li>
<li>coupon_name: the name of the coupon used</li>
<li>content_name: the product's numbers</li>
<li>transaction_id: the order's id</li>
<li>hour: the transaction's hour interval, based on the client's browser's time</li>
<li>day: the transaction's day, based on the client's browser's time</li>
<li>month: the transaction's month, based on the client's browser's time</li>
<li>traffic_source: direct</li>
<li>UTMs: the UMTs of the landing URL</li>
</ul>
</div>
<div id="pys-edd_ga_enhanced_ecommerce_params" style="display: none; visibility: hidden">
<p>In-depth e-commerce data will be sent to Google Analytics, like transaction value, tax, shipping, products, and
product categories. Product views, add to cart, remove from cart, checkout, and purchases are tracked
automatically and you can analyze and compare the stats inside Google Analytics E-commerce reports.</p>
</div>
<div id="pys-edd_google_ads_enhanced_ecommerce_params" style="display: none; visibility: hidden">
<p>The <a href="https://www.pixelyoursite.com/?utm_source=pixelyoursite-free-plugin&utm_medium=plugin&utm_campaign=free-plugin-info-popup">pro version</a> implements the Google Ads tag (former AdWords). All
the e-commerce events will be sent to Google Ads. These events can be used for audiences. You can also configure
"conversions" to track your transactions. The e-commerce events will be Dynamic Remarketing ready. You can
select between the "Retail" or "Custom" vertical, according to your needs.</p>
</div>
<!-- @fixme: update texts -->
<div id="pys-edd_google_ads_enhanced_ecommerce_params" style="display: none; visibility: hidden">
<p>In-depth e-commerce data will be sent to Google Ads, like transaction value, tax, shipping, products, and
product categories. Product views, add to cart, remove from cart, checkout, and purchases are tracked
automatically and you can analyze and compare the stats inside Google Ads E-commerce reports.</p>
</div>
<div id="pys-edd_purchase_on_transaction" style="display: none; visibility: hidden">
<p>This will make sure that simple page refreshes or reloads won't affect your stats. Disable this option if you
plan to test the event.</p>
</div>
<div id="pys-edd_purchase_event_value" style="display: none; visibility: hidden">
<p><strong>Value is mandatory for this event.</strong></p>
<p>Your Purchase event value for your business might not be the exact value of the products or services, because you
have all sorts of costs included. You can use the order total, a percent of the total, or a fixed value.</p>
<p>We also added a "total" parameter for this event that will always reflect the full value of each purchase.</p>
<p>Note: Some experts think that Facebook will better optimize your ads when conversion value is smaller, making
sure that you don't overspend. It's a controversial theory, but one you can test yourself.</p>
</div>
<div id="pys-edd_initiate_checkout_event_value" style="display: none; visibility: hidden">
<p>Value is not mandatory for this event. If you want, you can enable and configure it to reflect the value this
event has for your business.</p>
</div>
<div id="pys-edd_add_to_cart_event_value" style="display: none; visibility: hidden">
<p>Value is not mandatory for this event. If you want, you can enable and configure it to reflect the value this
event has for your business.</p>
</div>
<div id="pys-edd_view_content_event_value" style="display: none; visibility: hidden">
<p>Value is not mandatory for this event. If you want, you can enable and configure it to reflect the value this
event has for your business.</p>
</div>
<!-- COMMON -->
<div id="pys-google_dynamic_remarketing_vertical" style="display: none; visibility: hidden">
<p>All the e-commerce events will have the required parameters for Google Ads Dynamic Remarketing.</p>
<p><strong>If you have access to Google Merchant</strong>, select the Retail vertical. In this case, the
following parameters will be added:</p>
<ul>
<li>ecomm_prodid</li>
<li>ecomm_pagetype</li>
<li>ecomm_totalvalue</li>
</ul>
<p>Dynamic Remarketing will be done through Google Merchant.</p>
<p><strong>If you don't have access to Google Merchant</strong>, select the Custom vertical. In this case,
the following parameters will be added:</p>
<ul>
<li>dynx_itemid</li>
<li>dynx_pagetype</li>
<li>dynx_totalvalue</li>
</ul>
<p>Dynamic Remarketing will be done using a Custom feed.</p>
</div>
<div id="pys-ads_woo_item_id_prefix" style="display: none; visibility: hidden">
<p>You can use this option to match the product ID that Google Ads Tag will use for the Dynamic Remarketing
parameters. The ID should be identical to the one used by your Google Merchant or Custom feed.</p>
</div>
<div id="pys-google_ads_conversion_label" style="display: none; visibility: hidden">
<p>Transform this event into a Google Ads conversion:</p>
<p>Create a conversion inside your Google Ads account, copy its label and paste it here.</p>
<p>If you have more than one Google Tags installed, select the same one where the conversion was created.</p>
<p><a href="https://www.pixelyoursite.com/documentation/track-google-ads-conversion-on-woocommerce"
target="_blank">Click here for details</a></p>
</div>
<div id="pys-ga_cross_domain_tracking" style="display: none; visibility: hidden">
<p>Cross-domain measurement makes it possible for Analytics to see sessions on two related sites (such as an
ecommerce site and a separate shopping cart site) as a single session.</p>
<p><a href="https://www.pixelyoursite.com/pixelyoursite-free-version/google-analytics-cross-domain-tracking"
target="_blank">Click here for help</a></p>
</div>

View File

@@ -0,0 +1,34 @@
<?php
namespace PixelYourSite;
if ( ! defined( 'ABSPATH' ) ) {
exit; // Exit if accessed directly.
}
?>
<div class="wrap" id="pys">
<h1><?php _e( 'PixelYourSite', 'pys' ); ?></h1>
<div class="pys_stat">
<div class="row">
<div class="col">
<h2 class="section-title">EDD Reports <?php renderProBadge(); ?></h2>
</div>
</div>
<div class="container">
<div class="row" style="padding:40px">
<div class="col text-center">
<p >With PixelYourSite Professional you can find out what ads generate your Easy Digital Downloads orders using UTMs, discover your traffic sources and landing pages.
</p>
<h3 class="text-center" style="margin-top:40px">Get detailed info about products sold by each campaign, ad set, or ad</h3>
<a href="https://www.pixelyoursite.com/easy-digital-downloads-first-party-reports/?utm_source=free-plugin-reports-page-edd&utm_medium=free-plugin-reports-page-edd&utm_campaign=free-plugin-reports-edd&utm_content=free-plugin-reports-page-edd&utm_term=free-plugin-reports-page-edd"
target="_blank" class="btn btn-save" style="margin-top:30px">Click to find more</a>
</div>
</div>
</div>
</div>
</div>

View File

@@ -0,0 +1,34 @@
<?php
namespace PixelYourSite;
if ( ! defined( 'ABSPATH' ) ) {
exit; // Exit if accessed directly.
}
?>
<div class="wrap" id="pys">
<h1><?php _e( 'PixelYourSite', 'pys' ); ?></h1>
<div class="pys_stat">
<div class="row">
<div class="col">
<h2 class="section-title">WooCommerce Reports <?php renderProBadge(); ?></h2>
</div>
</div>
<div class="container">
<div class="row" style="padding:40px">
<div class="col text-center">
<p >Find out what ads generate your WooCommerce orders using UTMs, discover your traffic sources and landing pages.
Visualize your data inside the plugin, or download it as CSV. </p>
<h3 class="text-center" style="margin-top:40px">Get detailed info about products sold by each campaign, ad set, or ad</h3>
<a href="https://www.pixelyoursite.com/woocommerce-first-party-reports?utm_source=free-plugin-reports-page-woo&utm_medium=free-plugin-reports-page-woo&utm_campaign=free-plugin-reports-page-woo&utm_content=free-plugin-reports-page-woo&utm_term=free-plugin-reports-page-woo"
target="_blank" class="btn btn-save" style="margin-top:30px">Click to find more</a>
</div>
</div>
</div>
</div>
</div>

View File

@@ -0,0 +1,59 @@
<?php
namespace PixelYourSite;
if ( ! defined( 'ABSPATH' ) ) {
exit; // Exit if accessed directly.
}
?>
<div class="wrap" id="pys">
<h1><?php _e( 'PixelYourSite', 'pys' ); ?></h1>
<div class="container">
<div class="row">
<div class="col">
<h2 class="section-title">System Report</h2>
<?php foreach ( get_system_report_data() as $section_name => $section_report ) : ?>
<div class="card card-static">
<div class="card-header">
<?php esc_html_e( $section_name ); ?>
</div>
<div class="card-body">
<table class="table system-report">
<tbody>
<?php foreach ( $section_report as $name => $value ) : ?>
<tr>
<td style="width: 50%;"><?php echo $name; ?></td>
<td style="width: 50%;"><?php echo $value; ?></td>
</tr>
<?php endforeach; ?>
</tbody>
</table>
</div>
</div>
<?php endforeach; ?>
</div>
</div>
<hr>
<div class="row justify-content-center">
<div class="col-4">
<form method="post">
<?php wp_nonce_field( 'pys_download_system_report_nonce' ); ?>
<input type="hidden" name="pys_action" value="download_system_report"/>
<button type="submit" class="btn btn-block btn-sm btn-primary">Download System Report</button>
</form>
</div>
</div>
</div>
</div>

View File

@@ -0,0 +1,25 @@
<?php
namespace PixelYourSite;
if ( ! defined( 'ABSPATH' ) ) {
exit; // Exit if accessed directly.
}
?>
<div class="card card-static border-danger">
<div class="card-header bg-danger text-white">
Reset All Settings To Defaults
</div>
<div class="card-body">
<p><strong>If you continue, all your custom settings will be lost and the plugin will go back to the default
configuration.</strong> If you use any add-ons, like the Pinterest add-on or the Super Pack, their
settings will be affected too. Custom events and scripts added with the Head & Footer option won't be
affected.</p>
<button type="submit" name="pys[reset_settings]" value="1"
class="btn btn-sm btn-danger">Yes, reset settings</button>
<a href="<?php echo esc_url( buildAdminUrl( 'pixelyoursite' ) ); ?>"
class="btn btn-sm btn-light ml-3">No, go back</a>
</div>
</div>

View File

@@ -0,0 +1,87 @@
<?php
namespace PixelYourSite;
if ( ! defined( 'ABSPATH' ) ) {
exit; // Exit if accessed directly.
}
$utms = [
"utm_source",
"utm_medium",
"utm_campaign",
"utm_content",
"utm_term",
];
?>
<div class="wrap" id="pys">
<h1><?php _e( 'UTM Templates', 'pys' ); ?></h1>
<div class="pys_utm_templates container">
<div class="row">
<div class="col">
<div class="mb-2" >Meta (Facebook) - <a target="_blank" href="https://www.youtube.com/watch?v=aAJcjurzp-Q">watch video:</a></div>
<div class="utm_template mt-2 copy_text">utm_source=facebook&utm_medium=paid&utm_campaign={{campaign.name}}&utm_term={{adset.name}}&utm_content={{ad.name}}&fbadid={{ad.id}}</div>
</div>
</div>
<div class="row mt-4">
<div class="col">
<div class="mb-2" >Google Ads - <a target="_blank" href="https://www.youtube.com/watch?v=j1TlbKYNZk4">watch video:</a></div>
<div class="utm_template mt-2 copy_text">{lpurl}?utm_source=google&utm_medium=paid&utm_campaign={campaignid}&utm_content={adgroupid}&utm_term={keyword}&gadid={creative}</div>
</div>
</div>
<div class="row mt-4">
<div class="col">
<div class="mb-2" >TikTok - <a target="_blank" href="https://www.youtube.com/watch?v=bB2OVtlpQ5g">watch video:</a></div>
<div class="utm_template mt-2 copy_text">?utm_source=tiktok&utm_medium=paid&utm_campaign=__CAMPAIGN_NAME__&utm_term=__AID_NAME__&utm_content=__CID_NAME__&ttadid=__CID__</div>
</div>
</div>
<div class="row mt-4">
<div class="col">
<div class="mb-2" >Pinterest - <a target="_blank" href="https://www.youtube.com/watch?v=MKdS0PiND7M">watch video:</a></div>
<div class="utm_template mt-2 copy_text">?utm_source=pinterest&utm_medium=paid&utm_campaign={campaign_name}&utm_term={adgroup_name}&utm_content={creative_id}&padid={adid}</div>
</div>
</div>
<div class="row mt-4">
<div class="col">
<div class="mb-2" >Bing - <a target="_blank" href="https://www.youtube.com/watch?v=lC6c-Pt5fxM">watch video:</a></div>
<div class="utm_template mt-2 copy_text">{lpurl}?utm_source=bing&utm_medium=paid&utm_campaign={campaign}&utm_content={AdGroupId}&utm_term={AdGroup}&bingid={CampaignId}</div>
</div>
</div>
</div>
<h1><?php _e( 'UTM Builder', 'pys' ); ?></h1>
<div class="pys_utm_builder container">
<div class="bg-gray">
<h4 class="label">Your URL:</h4>
<input type="text" class="site_url form-control mt-2" value="<?=get_site_url();?>"/>
</div>
<?php
foreach ($utms as $utm) : ?>
<div >
<h4 class="label"><?=$utm?>:</h4>
<input type="text" class="utm form-control mt-2 <?=$utm?>" value="" data-type="<?=$utm?>"/>
</div>
<?php endforeach; ?>
<div class="">
<h4 class="label">URL with UTMs:</h4>
<div class="copy_text build_utms_with_url mt-2 bg-gray" ></div>
</div>
<div class="">
<h4 class="label">UTMs:</h4>
<div class="copy_text build_utms mt-2 bg-gray" ></div>
</div>
</div>
</div>

View File

@@ -0,0 +1,261 @@
<?php
namespace PixelYourSite;
if ( ! defined( 'ABSPATH' ) ) {
exit; // Exit if accessed directly.
}
/** @var PYS $this */
include "html-popovers.php";
?>
<div class="wrap">
<h1><?php _e( 'PixelYourSite', 'pys' ); ?></h1>
<div id="pys">
<div class="container">
<form method="post" enctype="multipart/form-data">
<?php wp_nonce_field( 'pys_save_settings' ); ?>
<div class="row mb-3">
<div class="col">
<nav class="nav nav-tabs">
<?php foreach ( getAdminPrimaryNavTabs() as $tab_key => $tab_data ) : ?>
<?php
$classes = array(
'nav-item',
'nav-link',
);
if ( $tab_key == getCurrentAdminTab() ) {
$classes[] = 'active';
}
$classes = implode( ' ', $classes );
if(isset($tab_data['class']) ) {
$classes .= ' '.$tab_data['class'];
}
?>
<a class="<?php esc_attr_e( $classes ); ?>"
href="<?php echo esc_url( $tab_data['url'] ); ?>">
<?php esc_html_e( $tab_data['name'] ); ?>
</a>
<?php endforeach; ?>
</nav>
</div>
</div>
<div class="row">
<div class="col-9">
<?php
switch ( getCurrentAdminTab() ) {
case 'general':
include "html-main-general.php";
break;
case 'events':
if ( getCurrentAdminAction() == 'edit' ) {
include "html-main-events-edit.php";
} else {
include "html-main-events.php";
}
break;
case 'woo':
include "html-main-woo.php";
break;
case 'edd':
include "html-main-edd.php";
break;
case 'wcf':
include "html-main-wcf.php";
break;
case 'head_footer':
/** @noinspection PhpIncludeInspection */
include PYS_FREE_PATH . '/modules/head_footer/views/html-admin-page.php';
break;
case 'facebook_settings':
/** @noinspection PhpIncludeInspection */
include PYS_FREE_PATH . '/modules/facebook/views/html-settings.php';
break;
case 'ga_settings':
/** @noinspection PhpIncludeInspection */
include PYS_FREE_PATH . '/modules/google_analytics/views/html-settings.php';
break;
case 'superpack_settings':
/** @noinspection PhpIncludeInspection */
include PYS_FREE_PATH . '/modules/superpack/views/html-settings.php';
break;
case 'gdpr':
include "html-gdpr.php";
break;
case 'reset_settings':
include "html-reset.php";
break;
case 'logs':
include "html-logs.php";
break;
default:
do_action( 'pys_admin_' . getCurrentAdminTab() );
}
?>
<p class="text-center mt-3 mb-0">
<a href="https://wordpress.org/support/plugin/pixelyoursite/reviews/?filter=5#new-post" target="_blank">Click here to give us a 5 stars review.</a> A huge thanks from the PixelYourSite team!
</p>
</div>
<div class="col-3">
<div class="card card-static border-primary">
<div class="card-body">
<p class="card-text">Track every key action and improve your ads return with the PRO
version:</p>
<a href="https://www.pixelyoursite.com/facebook-pixel-plugin/buy-pixelyoursite-pro?utm_source=pixelyoursite-free-plugin&utm_medium=plugin&utm_campaign=free-plugin-upgrade-orange"
target="_blank" class="btn btn-block btn-save">UPGRADE</a>
</div>
</div>
<nav class="nav nav-pills flex-column mb-3">
<?php foreach ( getAdminSecondaryNavTabs() as $tab_key => $tab_data ) : ?>
<?php
$classes = array(
'nav-item',
'nav-link',
);
if ( $tab_key == getCurrentAdminTab() ) {
$classes[] = 'active';
}
$classes = implode( ' ', $classes );
?>
<a class="<?php esc_attr_e( $classes ); ?>"
href="<?php echo esc_url( $tab_data['url'] ); ?>">
<?php esc_html_e( $tab_data['name'] ); ?>
</a>
<?php endforeach; ?>
<a class="nav-item nav-link" href="https://www.pixelyoursite.com/pixelyoursite-free-version?utm_source=pixelyoursite-free-plugin&utm_medium=plugin&utm_campaign=free-plugin-right-menu"
target="_blank" style="font-weight: bold;">HELP</a>
<a class="nav-item nav-link" href="https://www.pixelyoursite.com/video?utm_source=pixelyoursite-free-plugin&utm_medium=plugin&utm_campaign=free-plugin-right-menu"
target="_blank" style="font-weight: bold;">VIDEO TIPS</a>
<a href="<?php echo esc_url( buildAdminUrl( 'pixelyoursite', 'logs' ) ); ?>"
class="nav-item nav-link">Logs</a>
</nav>
<?php if ( 'woo' == getCurrentAdminTab() ) : ?>
<div class="card card-static border-disabled mb-5">
<div class="card-body" style="border-top: 0;">
<h4 class="card-title">Custom Audience File Export</h4>
<p class="card-text">Export a customer file with lifetime value. Use it to create a
Custom Audience and a Value-Based Lookalike Audience. More details
<a href="https://www.pixelyoursite.com/value-based-facebook-lookalike-audiences?utm_source=free&utm_medium=plugin&utm_campaign=right-column-free"
target="_blank">here</a>.</p>
<p style="text-align: center;"><?php renderProBadge(); ?></p>
<button type="submit" disabled="disabled" class="btn btn-sm btn-block btn-disabled">
Export clients LTV file
</button>
</div>
</div>
<?php endif; ?>
<?php if ( 'edd' == getCurrentAdminTab() ) : ?>
<div class="card card-static border-disabled mb-5">
<div class="card-body" style="border-top: 0;">
<h4 class="card-title">Custom Audience File Export</h4>
<p class="card-text">Export a customer file with lifetime value. Use it to create a
Custom Audience and a Value-Based Lookalike Audience. More details
<a href="https://www.pixelyoursite.com/value-based-facebook-lookalike-audiences?utm_source=free&utm_medium=plugin&utm_campaign=right-column-free"
target="_blank">here</a>.</p>
<p style="text-align: center;"><?php renderProBadge(); ?></p>
<button type="submit" disabled="disabled" class="btn btn-sm btn-block btn-disabled">
Export clients LTV file
</button>
</div>
</div>
<?php endif; ?>
<?php if ( ! isProductCatalogFeedProActive() ) : ?>
<div class="card card-static border-primary">
<div class="card-body">
<h4 class="card-title">WooCommerce Product Catalog Feeds</h4>
<p class="card-text">Generate auto-updating WooCommerce XML feeds for Facebook Product
Catalog, Google Merchant, and Google Ads (custom type).</p>
<a href="https://www.pixelyoursite.com/product-catalog-facebook?utm_source=free&utm_medium=plugin&utm_campaign=right-column-free" target="_blank"
class="btn btn-sm btn-block btn-primary">Click for details</a>
</div>
</div>
<?php endif; ?>
<?php if ( ! isEddProductsFeedProActive() ) : ?>
<div class="card card-static border-primary">
<div class="card-body">
<h4 class="card-title">Easy Digital Downloads Product Catalog Feeds</h4>
<p class="card-text">Generate auto-updating EDD XML feeds for Facebook Product Catalog.</p>
<a href="https://www.pixelyoursite.com/easy-digital-downloads-product-catalog?utm_source=free&utm_medium=plugin&utm_campaign=right-column-free"
target="_blank" class="btn btn-sm btn-block btn-primary">Click for details</a>
</div>
</div>
<?php endif; ?>
<?php if ( !isConsentMagicPluginActivated() ) : ?>
<div class="card card-static border-primary">
<div class="card-body">
<h4 class="card-title">ConsentMagic</h4>
<p class="card-text">Persuade your visitors to agree to tracking, while respecting the legal requirements. Inform, opt-out, or block tracking when needed.</p>
<a href="https://www.pixelyoursite.com/plugins/consentmagic?utm_source=free&utm_medium=plugin&utm_campaign=right-column-free" target="_blank"
class="btn btn-sm btn-block btn-primary">Click for details</a>
</div>
</div>
<?php endif; ?>
<?php if ( !isPixelCogActive() ) : ?>
<div class="card card-static border-primary">
<div class="card-body">
<h4 class="card-title">WooCommerce Cost of Goods</h4>
<p class="card-text">Add the cost of your products, calculate profit for each order, track the profit with PixelYourSite WooCommerce first-party reports.</p>
<a href="https://www.pixelyoursite.com/plugins/woocommerce-cost-of-goods?utm_source=free&utm_medium=plugin&utm_campaign=right-column-free" target="_blank"
class="btn btn-sm btn-block btn-primary">Click for details</a>
</div>
</div>
<?php endif; ?>
<?php if ( getCurrentAdminTab() !== 'reset_settings' ) : ?>
<a href="<?php echo esc_url( buildAdminUrl( 'pixelyoursite', 'reset_settings' ) ); ?>"
class="btn btn-sm btn-block btn-light mt-5">Reset all settings to defaults</a>
<?php endif; ?>
</div>
</div>
</form>
</div>
</div>
</div>