Version Notes
Repackaged
Download this release
Release Info
Developer | Listrak |
Extension | Listrak_Remarketing |
Version | 1.0.7 |
Comparing to | |
See all releases |
Code changes from version 1.0.5 to 1.0.7
- app/code/community/Listrak/Remarketing/Block/Ecjs.php +0 -20
- app/code/community/Listrak/Remarketing/Model/Apiextension/Api.php +1 -1
- app/code/community/Listrak/Remarketing/Model/Click.php +2 -2
- app/code/community/Listrak/Remarketing/controllers/CartController.php +19 -12
- app/code/community/Listrak/Remarketing/etc/config.xml +1 -1
- app/code/community/Listrak/Remarketing/sql/listrak_remarketing_setup/mysql4-install-1.0.0.php +6 -0
- package.xml +5 -5
app/code/community/Listrak/Remarketing/Block/Ecjs.php
CHANGED
@@ -1,27 +1,7 @@
|
|
1 |
<?php
|
2 |
// Listrak Remarketing Magento Extension Ver. 1.0.0
|
3 |
// © 2011 Listrak, Inc.
|
4 |
-
/**
|
5 |
-
arrEcjs = [];
|
6 |
-
arrEcjs.push({id:'billing:email', fn:function() _ecjs(1, $(this).value)});
|
7 |
-
arrEcjs.push({id:'login:email', fn:function() _ecjs(2, $(this).value)});
|
8 |
|
9 |
-
function ecjsInit() {
|
10 |
-
for(var i = 0; i < arrEcjs.length; i++) {
|
11 |
-
$(arrEcjs[i].id).stopObserving('change', arrEcjs[i].fn);
|
12 |
-
$(arrEcjs[i].id).observe('change', arrEcjs[i].fn);
|
13 |
-
}
|
14 |
-
}
|
15 |
-
|
16 |
-
Ajax.Responders.register({
|
17 |
-
onComplete: function() {
|
18 |
-
ecjsInit();
|
19 |
-
}
|
20 |
-
});
|
21 |
-
|
22 |
-
|
23 |
-
*/
|
24 |
-
|
25 |
class Listrak_Remarketing_Block_Ecjs extends Mage_Core_Block_Text
|
26 |
{
|
27 |
|
1 |
<?php
|
2 |
// Listrak Remarketing Magento Extension Ver. 1.0.0
|
3 |
// © 2011 Listrak, Inc.
|
|
|
|
|
|
|
|
|
4 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
5 |
class Listrak_Remarketing_Block_Ecjs extends Mage_Core_Block_Text
|
6 |
{
|
7 |
|
app/code/community/Listrak/Remarketing/Model/Apiextension/Api.php
CHANGED
@@ -86,7 +86,7 @@ class Listrak_Remarketing_Model_Apiextension_Api extends Mage_Api_Model_Resource
|
|
86 |
->addFieldToFilter('updated_at',array('from'=>$startDate, 'to'=>$endDate))
|
87 |
->addFieldToFilter('status', array('neq'=>'pending'))
|
88 |
->setPageSize($perPage)->setCurPage($page)
|
89 |
-
->setOrder('
|
90 |
|
91 |
if (is_array($filters)) {
|
92 |
try {
|
86 |
->addFieldToFilter('updated_at',array('from'=>$startDate, 'to'=>$endDate))
|
87 |
->addFieldToFilter('status', array('neq'=>'pending'))
|
88 |
->setPageSize($perPage)->setCurPage($page)
|
89 |
+
->setOrder('updated_at', 'ASC');
|
90 |
|
91 |
if (is_array($filters)) {
|
92 |
try {
|
app/code/community/Listrak/Remarketing/Model/Click.php
CHANGED
@@ -11,7 +11,7 @@ class Listrak_Remarketing_Model_Click extends Mage_Core_Model_Abstract
|
|
11 |
}
|
12 |
|
13 |
public function checkForClick() {
|
14 |
-
foreach(
|
15 |
if(stripos($key, 'trk_') !== false) {
|
16 |
$this->recordClick();
|
17 |
break;
|
@@ -23,7 +23,7 @@ class Listrak_Remarketing_Model_Click extends Mage_Core_Model_Abstract
|
|
23 |
$this->setTokenUid(Mage::helper('remarketing')->gen_uuid());
|
24 |
$this->setClickDate(gmdate('Y-m-d H:i:s'));
|
25 |
$this->setSessionId(Mage::getSingleton('listrak/session')->getId());
|
26 |
-
$this->setQuerystring(
|
27 |
$this->save();
|
28 |
|
29 |
Mage::getModel('core/cookie')->set('ltktrk', $this->getTokenUid(), TRUE, NULL, NULL, NULL, TRUE);
|
11 |
}
|
12 |
|
13 |
public function checkForClick() {
|
14 |
+
foreach(Mage::app()->getRequest()->getParams() as $key => $value) {
|
15 |
if(stripos($key, 'trk_') !== false) {
|
16 |
$this->recordClick();
|
17 |
break;
|
23 |
$this->setTokenUid(Mage::helper('remarketing')->gen_uuid());
|
24 |
$this->setClickDate(gmdate('Y-m-d H:i:s'));
|
25 |
$this->setSessionId(Mage::getSingleton('listrak/session')->getId());
|
26 |
+
$this->setQuerystring(http_build_query(Mage::app()->getRequest()->getParams()));
|
27 |
$this->save();
|
28 |
|
29 |
Mage::getModel('core/cookie')->set('ltktrk', $this->getTokenUid(), TRUE, NULL, NULL, NULL, TRUE);
|
app/code/community/Listrak/Remarketing/controllers/CartController.php
CHANGED
@@ -18,27 +18,23 @@ class Listrak_Remarketing_CartController extends Mage_Core_Controller_Front_Acti
|
|
18 |
|
19 |
try {
|
20 |
if(!$ltksid) {
|
21 |
-
return $this->
|
22 |
}
|
23 |
|
24 |
if(!empty($ltksidcookie) && $ltksidcookie == $ltksid) {
|
25 |
-
return $this->
|
26 |
}
|
27 |
|
28 |
$ltksession->setSessionId($ltksid);
|
29 |
$ltksession->getResource()->loadBySessionId($ltksession);
|
30 |
|
31 |
-
if(!$ltksession->getId()) {
|
32 |
-
|
33 |
-
}
|
34 |
-
|
35 |
-
if(!$ltksession->getQuoteId()) {
|
36 |
-
die("");
|
37 |
}
|
38 |
|
39 |
if($cust && $cust->isLoggedIn()) {
|
40 |
if($cust->getId() === $ltksession->getCustomerId()) {
|
41 |
-
return $this->
|
42 |
}
|
43 |
}
|
44 |
|
@@ -47,14 +43,25 @@ class Listrak_Remarketing_CartController extends Mage_Core_Controller_Front_Acti
|
|
47 |
if($quote->getId() && $quote->getIsActive()) {
|
48 |
$checkout->setQuoteId($ltksession->getQuoteId());
|
49 |
}
|
50 |
-
else {
|
51 |
-
}
|
52 |
}
|
53 |
catch(Exception $ex) {
|
54 |
Mage::getModel("listrak/log")->addException($e);
|
55 |
}
|
56 |
|
57 |
-
return $this->
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
58 |
}
|
59 |
}
|
60 |
|
18 |
|
19 |
try {
|
20 |
if(!$ltksid) {
|
21 |
+
return $this->redirect();
|
22 |
}
|
23 |
|
24 |
if(!empty($ltksidcookie) && $ltksidcookie == $ltksid) {
|
25 |
+
return $this->redirect();
|
26 |
}
|
27 |
|
28 |
$ltksession->setSessionId($ltksid);
|
29 |
$ltksession->getResource()->loadBySessionId($ltksession);
|
30 |
|
31 |
+
if(!$ltksession->getId() || !$ltksession->getQuoteId()) {
|
32 |
+
return $this->redirect();
|
|
|
|
|
|
|
|
|
33 |
}
|
34 |
|
35 |
if($cust && $cust->isLoggedIn()) {
|
36 |
if($cust->getId() === $ltksession->getCustomerId()) {
|
37 |
+
return $this->redirect();
|
38 |
}
|
39 |
}
|
40 |
|
43 |
if($quote->getId() && $quote->getIsActive()) {
|
44 |
$checkout->setQuoteId($ltksession->getQuoteId());
|
45 |
}
|
|
|
|
|
46 |
}
|
47 |
catch(Exception $ex) {
|
48 |
Mage::getModel("listrak/log")->addException($e);
|
49 |
}
|
50 |
|
51 |
+
return $this->redirect();
|
52 |
+
}
|
53 |
+
|
54 |
+
private function redirect() {
|
55 |
+
$qs = $this->getRequest()->getParams();
|
56 |
+
unset($qs["redirectUrl"]);
|
57 |
+
unset($qs["ltksid"]);
|
58 |
+
$qs["_secure"] = Mage::app()->getStore()->isCurrentlySecure();
|
59 |
+
|
60 |
+
if(!$this->getRequest()->getParam('redirectUrl')) {
|
61 |
+
return $this->_redirect('checkout/cart/', $qs);
|
62 |
+
}
|
63 |
+
|
64 |
+
return $this->_redirect($this->getRequest()->getParam('redirectUrl'), $qs);
|
65 |
}
|
66 |
}
|
67 |
|
app/code/community/Listrak/Remarketing/etc/config.xml
CHANGED
@@ -7,7 +7,7 @@
|
|
7 |
<config>
|
8 |
<modules>
|
9 |
<Listrak_Remarketing>
|
10 |
-
<version>1.0.
|
11 |
</Listrak_Remarketing>
|
12 |
</modules>
|
13 |
<frontend>
|
7 |
<config>
|
8 |
<modules>
|
9 |
<Listrak_Remarketing>
|
10 |
+
<version>1.0.7</version>
|
11 |
</Listrak_Remarketing>
|
12 |
</modules>
|
13 |
<frontend>
|
app/code/community/Listrak/Remarketing/sql/listrak_remarketing_setup/mysql4-install-1.0.0.php
CHANGED
@@ -77,6 +77,12 @@ try {
|
|
77 |
$client = new Varien_Http_Client("http://magento.listrakbi.com/Install.ashx");
|
78 |
$client->setMethod(Varien_Http_Client::POST);
|
79 |
$client->setParameterPost("homeUrl",Mage::getBaseUrl());
|
|
|
|
|
|
|
|
|
|
|
|
|
80 |
$client->request();
|
81 |
}
|
82 |
catch(Exception $e) { }
|
77 |
$client = new Varien_Http_Client("http://magento.listrakbi.com/Install.ashx");
|
78 |
$client->setMethod(Varien_Http_Client::POST);
|
79 |
$client->setParameterPost("homeUrl",Mage::getBaseUrl());
|
80 |
+
$versionInfo = Mage::getVersionInfo();
|
81 |
+
|
82 |
+
foreach($versionInfo as $vi => $vi2) {
|
83 |
+
$client->setParameterPost($vi, $vi2);
|
84 |
+
}
|
85 |
+
|
86 |
$client->request();
|
87 |
}
|
88 |
catch(Exception $e) { }
|
package.xml
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>Listrak_Remarketing</name>
|
4 |
-
<version>1.0.
|
5 |
<stability>stable</stability>
|
6 |
<license uri="http://s1.listrakbi.com/licenses/magento.txt">Listrak EULA</license>
|
7 |
<channel>community</channel>
|
@@ -16,11 +16,11 @@
|
|
16 |
- Tracks clicks from Listrak emails for conversion reporting
|
17 |
- Synchronizes Magento newsletter subscriptions with your Listrak account
|
18 |
</description>
|
19 |
-
<notes>
|
20 |
<authors><author><name>Listrak</name><user>Listrak</user><email>magento@listrak.com</email></author></authors>
|
21 |
-
<date>2012-01-
|
22 |
-
<time>2012-01-
|
23 |
-
<contents><target name="magecommunity"><dir name="Listrak"><dir name="Remarketing"><dir name="Block"><dir name="Adminhtml"><dir name="Abandonedcartreport"><file name="Grid.php" hash="6c9975250ee0d3318fe1a996e19b554f"/></dir><file name="Abandonedcartreport.php" hash="5c348aeec1c636b39ac037b5abc1875a"/><dir name="Emailcapture"><dir name="Edit"><file name="Form.php" hash="dae25c78913b35bb3ad64da797cd82b4"/><dir name="Tab"><file name="Form.php" hash="d1b495e77fd135af95457ee7c3f1f21c"/></dir><file name="Tabs.php" hash="b7c89cd1e1fae23ed52079c6d63ef4ee"/></dir><file name="Edit.php" hash="6a06c2b0dfb5a0414a642bc0cd3b5461"/><file name="Grid.php" hash="9eca43e603861ce2f24ec21a4d3a5064"/></dir><file name="Emailcapture.php" hash="accf0689467c5446e7605cad41e427b0"/><file name="Notifications.php" hash="dec4ef3882d5d11d738576787d05ec61"/></dir><file name="Ecjs.php" hash="
|
24 |
<compatible/>
|
25 |
<dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies>
|
26 |
</package>
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>Listrak_Remarketing</name>
|
4 |
+
<version>1.0.7</version>
|
5 |
<stability>stable</stability>
|
6 |
<license uri="http://s1.listrakbi.com/licenses/magento.txt">Listrak EULA</license>
|
7 |
<channel>community</channel>
|
16 |
- Tracks clicks from Listrak emails for conversion reporting
|
17 |
- Synchronizes Magento newsletter subscriptions with your Listrak account
|
18 |
</description>
|
19 |
+
<notes>Repackaged</notes>
|
20 |
<authors><author><name>Listrak</name><user>Listrak</user><email>magento@listrak.com</email></author></authors>
|
21 |
+
<date>2012-01-23</date>
|
22 |
+
<time>2012-01-23</time>
|
23 |
+
<contents><target name="magecommunity"><dir name="Listrak"><dir name="Remarketing"><dir name="Block"><dir name="Adminhtml"><dir name="Abandonedcartreport"><file name="Grid.php" hash="6c9975250ee0d3318fe1a996e19b554f"/></dir><file name="Abandonedcartreport.php" hash="5c348aeec1c636b39ac037b5abc1875a"/><dir name="Emailcapture"><dir name="Edit"><file name="Form.php" hash="dae25c78913b35bb3ad64da797cd82b4"/><dir name="Tab"><file name="Form.php" hash="d1b495e77fd135af95457ee7c3f1f21c"/></dir><file name="Tabs.php" hash="b7c89cd1e1fae23ed52079c6d63ef4ee"/></dir><file name="Edit.php" hash="6a06c2b0dfb5a0414a642bc0cd3b5461"/><file name="Grid.php" hash="9eca43e603861ce2f24ec21a4d3a5064"/></dir><file name="Emailcapture.php" hash="accf0689467c5446e7605cad41e427b0"/><file name="Notifications.php" hash="dec4ef3882d5d11d738576787d05ec61"/></dir><file name="Ecjs.php" hash="cf76b48f16204ccfc815b785ad04e856"/></dir><dir name="Helper"><file name="Data.php" hash="bd33bd2e7c3b6cf34cc28499a1f2eb7f"/></dir><dir name="Model"><dir name="Abandonedcart"><dir name="Api"><file name="V2.php" hash="c7b46e1feab677e41f4f9a3914e415fb"/></dir><file name="Api.php" hash="904d3c39e295d3190c2d4f683fb63f2b"/></dir><file name="Abandonedcart.php" hash="2bd672054843917133e3ac7d941be42c"/><dir name="Apiextension"><dir name="Api"><file name="V2.php" hash="ff5a5f68d92c8a790bb00282c30c1378"/></dir><file name="Api.php" hash="e1474c9f9f5651f67dc4dae06d215a99"/></dir><file name="Apiextension.php" hash="1a5964f749523d74c648d6609673fb08"/><dir name="Click"><dir name="Api"><file name="V2.php" hash="510ae6b8032ff54b5f43d94f447f35e2"/></dir><file name="Api.php" hash="b22605c25dd1336188a62fbbecc177bf"/></dir><file name="Click.php" hash="8c7e2d5eba20c24fdf3fcf516c772001"/><file name="Emailcapture.php" hash="4987ceda6dda7ca134736895e3cfed74"/><dir name="Log"><dir name="Api"><file name="V2.php" hash="ace9ca737ebefd47205886fdef504a05"/></dir><file name="Api.php" hash="2a2a52b419cb90c0648209964b961287"/></dir><file name="Log.php" hash="577b2308bdbc531c867c67277d513371"/><dir name="Mysql4"><dir name="Abandonedcart"><file name="Collection.php" hash="bf8688e036707913ce393c310e2b3546"/></dir><file name="Abandonedcart.php" hash="446945e10c03137241f2d1eefd8668b6"/><file name="Apiextension.php" hash="4bbee7324ff4e6e4ca70587b023da6a0"/><dir name="Click"><file name="Collection.php" hash="41ff4606dff463ddac76e790a5d9d8d5"/></dir><file name="Click.php" hash="baabaf95e4d4f7f3fb1a2ac1c1965984"/><dir name="Emailcapture"><file name="Collection.php" hash="4dbc86c599e6a390e1f8bde7752f09c2"/></dir><file name="Emailcapture.php" hash="b68ee210c3bcec8f2fccef7979b022b7"/><dir name="Log"><file name="Collection.php" hash="1765ae33eb74e9593d8266702cfe4160"/></dir><file name="Log.php" hash="e244d19b857ee9d03a7955a30d3f6cf3"/><dir name="Session"><file name="Collection.php" hash="c095fdf0c54184df63ff6dd8636d779e"/></dir><file name="Session.php" hash="454a2c56529a0db4db3a5b8473952f78"/><dir name="Subscriberupdate"><file name="Collection.php" hash="1fd68314a80e93f416815273f29bf9f5"/></dir><file name="Subscriberupdate.php" hash="4957865b4aa8bbdda3a50484d7e49880"/></dir><file name="Observer.php" hash="375845e1ff616e7fa1736ab90335f989"/><file name="Session.php" hash="022a065dcbc893cec1eab6a89863c089"/><file name="Subscriber.php" hash="7addcff01d1c12e88baad9064a362f2c"/><file name="Subscriberupdate.php" hash="77df791c2d17772345f518ce3b4dab90"/></dir><dir name="controllers"><dir name="Adminhtml"><file name="AbandonedcartreportController.php" hash="e1a2c2db0c6cc8cc30f9fdf26636c1a0"/><file name="EmailcaptureController.php" hash="ad7c87ca689bc30eb135fc5d25ae21a2"/></dir><file name="CartController.php" hash="7d6b0bad06d0b0be1ed657f444666b5c"/><file name="ConfigController.php" hash="7250d699110107b35fa004833dc3595e"/><file name="EmailController.php" hash="7b9e1711e0c964876b8afe46dde9266b"/><file name="TroubleshootingController.php" hash="8e9355a2c91ee3508620fc893aabe050"/></dir><dir name="etc"><file name="adminhtml.xml" hash="0e01a6415641c271f4eb3067419c7f0a"/><file name="api.xml" hash="9e261fb5bfd7fc24870a8f8af5c9b226"/><file name="config.xml" hash="bd1d74629da08ac15380f77e23abcd1b"/><file name="system.xml" hash="f607244296525660dd23c0cec26657fa"/><file name="wsdl.xml" hash="d354dcaaaa2ae4a7adc101f08c7284ee"/><file name="wsi.xml" hash="e6fc96537d37c0c688454442d05c637d"/></dir><dir name="sql"><dir name="listrak_remarketing_setup"><file name="mysql4-install-1.0.0.php" hash="d12bcc8b1ee2876c456b67ba6bec7951"/><file name="mysql4-upgrade-1.0.0-1.0.1.php" hash="51d6494a61a2e32907cdc8eaf078274c"/></dir></dir></dir></dir></target><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="remarketing.xml" hash="44d7027ba447c4aaf0841d32d185ffde"/></dir></dir></dir></dir><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="remarketing.xml" hash="b9959df6437595381e7e12b5313dab74"/></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Listrak_Remarketing.xml" hash="1fc68edb656e220874e64cffaf7f2dbd"/></dir></target></contents>
|
24 |
<compatible/>
|
25 |
<dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies>
|
26 |
</package>
|