From 750a189133f6802389028259bf7128f82b33c411 Mon Sep 17 00:00:00 2001 From: levani Date: Tue, 8 Jan 2019 15:34:49 +0400 Subject: [PATCH] Implement basic js implemetation --- gaOpOut.php | 31 ++++++++++++++++++++++++++----- 1 file changed, 26 insertions(+), 5 deletions(-) diff --git a/gaOpOut.php b/gaOpOut.php index e91db12..f7146a7 100644 --- a/gaOpOut.php +++ b/gaOpOut.php @@ -11,14 +11,35 @@ class gaOpOut { -//gap Id + // view + public $view; + //gap Id public $gaAppId; -//output call event + //output call event public $optOutCallEvent = 'click'; -//element selector with link to jsoutput + //element selector with link to jsoutput public $elementSelector = '[href="#jsgaoptout"]'; - -//Debug default false + //Debug default false public $debug = false; + public $showAlterAfterDeactivate = true; + + public function registerGaOpOut($view, $gaAppId, $optOutCallEvent, $elementSelector, $debug, $showAlterAfterDeactivate) + { + Assets::register($view); + $view->registerJs(" + "); + } } \ No newline at end of file