| Line 100... |
Line 100... |
| 100 |
<div><?php echo $recharge_orderconfirmation[0]->response->totalAmount ?></div>
|
100 |
<div><?php echo $recharge_orderconfirmation[0]->response->totalAmount ?></div>
|
| 101 |
</div>
|
101 |
</div>
|
| 102 |
</div><!--o-info-->
|
102 |
</div><!--o-info-->
|
| 103 |
|
103 |
|
| 104 |
</div><!--o-hldr-->
|
104 |
</div><!--o-hldr-->
|
| - |
|
105 |
<script type="text/javascript">
|
| - |
|
106 |
var orderConfirmation = <?php echo json_encode($orderConfirmation);?>;
|
| - |
|
107 |
if(orderConfirmation != undefined){
|
| - |
|
108 |
var amount = parseFloat(orderConfirmation['response'].totalAmount).toFixed(2);
|
| - |
|
109 |
var orderId = orderConfirmation['response'].rechargeDisplayId;
|
| - |
|
110 |
var deviceNumber = orderConfirmation['response'].rechargeDeviceNumber;
|
| - |
|
111 |
|
| - |
|
112 |
ga('ecommerce:addTransaction', {
|
| - |
|
113 |
'id': orderId, // Transaction ID. Required
|
| - |
|
114 |
'affiliation': 'Saholic', // Affiliation or store name
|
| - |
|
115 |
'revenue': amount, // Grand Total
|
| - |
|
116 |
'shipping': '0', // Shipping
|
| - |
|
117 |
'tax': '0' // Tax
|
| - |
|
118 |
});
|
| - |
|
119 |
// addItem should be called for every item in the shopping cart.
|
| - |
|
120 |
ga('ecommerce:addItem', {
|
| - |
|
121 |
'id': orderId, // Transaction ID. Required
|
| - |
|
122 |
'sku': deviceNumber, // SKU/code
|
| - |
|
123 |
'name': orderConfirmation['response'].rechargeProvider, // Product name. Required
|
| - |
|
124 |
'category': 'Digital', // Category or variation
|
| - |
|
125 |
'price': amount, // Unit price
|
| - |
|
126 |
'quantity': '1' // Quantity
|
| - |
|
127 |
});
|
| - |
|
128 |
ga('ecommerce:send'); // Send transaction and item data to Google Analytics.
|
| - |
|
129 |
}
|
| - |
|
130 |
var pheight = Math.max(document.documentElement.clientHeight, window.innerHeight || 0);
|
| - |
|
131 |
var value = localStorage.getItem('rechargeValue');
|
| - |
|
132 |
if(parseInt(value) == 1){
|
| - |
|
133 |
ga('send', 'event', 'Recharge', 'Recharge Result','Mobile-Result');
|
| - |
|
134 |
}else if(parseInt(value) == 2){
|
| - |
|
135 |
ga('send', 'event', 'Recharge', 'Recharge Result','Recharge-Result');
|
| - |
|
136 |
}
|
| - |
|
137 |
// if(document.getElementsByClassName('order-conf')[0] != undefined){
|
| - |
|
138 |
// document.getElementsByClassName('order-conf')[0].style.minHeight = pheight - 153 +'px';
|
| - |
|
139 |
// }
|
| - |
|
140 |
</script>
|
| 105 |
|
141 |
|
| 106 |
<?php $rechargestatus = array("RECHARGE IN PROCESS");?>
|
142 |
<?php $rechargestatus = array("RECHARGE IN PROCESS");?>
|
| 107 |
<?php
|
143 |
<?php
|
| 108 |
if(isset($privatedeals['response']['items']) && (!empty($privatedeals['response']['items']))){
|
144 |
if(isset($privatedeals['response']['items']) && (!empty($privatedeals['response']['items']))){
|
| 109 |
?>
|
145 |
?>
|
| Line 138... |
Line 174... |
| 138 |
</div>
|
174 |
</div>
|
| 139 |
</div><!--rec-hldr-->
|
175 |
</div><!--rec-hldr-->
|
| 140 |
</div><!--recomended-pd-->
|
176 |
</div><!--recomended-pd-->
|
| 141 |
<?php
|
177 |
<?php
|
| 142 |
}?>
|
178 |
}?>
|
| 143 |
<script type="text/javascript">
|
- |
|
| 144 |
var orderConfirmation = <?php echo json_encode($orderConfirmation);?>;
|
- |
|
| 145 |
if(orderConfirmation != undefined){
|
- |
|
| 146 |
var amount = parseFloat(orderConfirmation['response'].totalAmount).toFixed(2);
|
- |
|
| 147 |
var orderId = orderConfirmation['response'].rechargeDisplayId;
|
- |
|
| 148 |
var deviceNumber = orderConfirmation['response'].rechargeDeviceNumber;
|
- |
|
| 149 |
|
- |
|
| 150 |
ga('ecommerce:addTransaction', {
|
- |
|
| 151 |
'id': orderId, // Transaction ID. Required
|
- |
|
| 152 |
'affiliation': 'Saholic', // Affiliation or store name
|
- |
|
| 153 |
'revenue': amount, // Grand Total
|
- |
|
| 154 |
'shipping': '0', // Shipping
|
- |
|
| 155 |
'tax': '0' // Tax
|
- |
|
| 156 |
});
|
- |
|
| 157 |
// addItem should be called for every item in the shopping cart.
|
- |
|
| 158 |
ga('ecommerce:addItem', {
|
- |
|
| 159 |
'id': orderId, // Transaction ID. Required
|
- |
|
| 160 |
'sku': deviceNumber, // SKU/code
|
- |
|
| 161 |
'name': orderConfirmation['response'].rechargeProvider, // Product name. Required
|
- |
|
| 162 |
'category': 'Digital', // Category or variation
|
- |
|
| 163 |
'price': amount, // Unit price
|
- |
|
| 164 |
'quantity': '1' // Quantity
|
- |
|
| 165 |
});
|
- |
|
| 166 |
ga('ecommerce:send'); // Send transaction and item data to Google Analytics.
|
- |
|
| 167 |
}
|
- |
|
| 168 |
var pheight = Math.max(document.documentElement.clientHeight, window.innerHeight || 0);
|
- |
|
| 169 |
var value = localStorage.getItem('rechargeValue');
|
- |
|
| 170 |
if(parseInt(value) == 1){
|
- |
|
| 171 |
ga('send', 'event', 'Recharge', 'Recharge Result','Mobile-Result');
|
- |
|
| 172 |
}else if(parseInt(value) == 2){
|
- |
|
| 173 |
ga('send', 'event', 'Recharge', 'Recharge Result','Recharge-Result');
|
- |
|
| 174 |
}
|
- |
|
| 175 |
// if(document.getElementsByClassName('order-conf')[0] != undefined){
|
- |
|
| 176 |
// document.getElementsByClassName('order-conf')[0].style.minHeight = pheight - 153 +'px';
|
- |
|
| 177 |
// }
|
- |
|
| 178 |
</script>
|
- |
|