|
[x]
Posted via EE Mobile
|
||
Search, ask, and monitor your questions on the go with EE Mobile. Visit Experts Exchange from your mobile device and never be out of touch again. |
||
| Question |
|
[x]
Attachment Details
|
||
|
[x]
The Solution Rating System
|
||
With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.
Your Input Matters If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support. Thank you! |
||
1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12: 13: 14: 15: 16: 17: 18: 19: 20: 21: 22: 23: 24: 25: 26: 27: 28: 29: 30: 31: 32: 33: 34: 35: 36: 37: 38: 39: 40: 41: 42: 43: 44: 45: 46: 47: 48: 49: 50: 51: 52: 53: 54: 55: 56: 57: 58: 59: 60: 61: 62: 63: 64: 65: 66: 67: 68: 69: 70: 71: 72: 73: 74: 75: 76: 77: 78: |
<?php
# Google Analytics E-Commerce Tracking Code
if(!$sandbox && $google_analytics_ecommerce && strtolower($payment_status) == 'completed')
{
$js_output = '<script type="text/javascript">
var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
document.write(unescape("%3Cscript src=\'" + gaJsHost + "google-analytics.com/ga.js\' type=\'text/javascript\'%3E%3C/script%3E"));
</script>
<script type="text/javascript">
var pageTracker = _gat._getTracker("' . $google_analytics_id . '");
pageTracker._trackPageview();
pageTracker._addTrans(
"' . $invoice . '", // Order ID
"", // Affiliation
"' . $mc_gross . '", // Total
"' . $tax . '", // Tax
"' . $shipping . '", // Shipping
"' . $address_city . '", // City
"' . $address_state . '", // State
"' . $address_country . '" // Country
);';
foreach($cart_items as $cart_item)
{
$js_output .= 'pageTracker._addItem(
"' . $invoice . '", // Order ID
"' . $cart_item['item_number'] . '", // SKU
"' . $cart_item['item_name'] . '", // Product Name
"", // Category
"' . $cart_item['mc_gross'] . '", // Price
"' . $cart_item['quantity'] . '" // Quantity
);';
}
$js_output .= 'pageTracker._trackTrans();
</script>';
echo $js_output . chr(10) . chr(10);
}
$js_output_email = isset($js_output) ? $js_output : '';
# Google Analytics AdWords Conversion Tracking
if(!$sandbox && $google_adwords_conversions && strtolower($payment_status) == 'completed')
{
$js_output = '<script language="JavaScript" type="text/javascript">
<!--
var google_conversion_id = ' . $google_adwords_conversion_id . ';
var google_conversion_language = "en_US";
var google_conversion_format = "3";
var google_conversion_color = "ffffff";
var google_conversion_label = "XNx1CM7GWBCmxJr2Aw";
if (' . number_format($mc_gross,1) . ') {
var google_conversion_value = ' . number_format($mc_gross,1) . ';
}
//-->
</script>
<script language="JavaScript" src="https://www.googleadservices.com/pagead/conversion.js">
</script>
<noscript>
<img height="1" width="1" border="0" src="https://www.googleadservices.com/pagead/conversion/' . $google_adwords_conversion_id . '/?value=' . number_format($mc_gross,1) . '&label=XNx1CM7GWBCmxJr2Aw&guid=ON&script=0"/>
</noscript>';
echo $js_output;
}
# Temp to see if this get reached
if(isset($js_output))
{
$js_output_email .= $js_output;
$mail -> Subject = 'USBSwiper PayPal IPN : Google Analytics Code Ran';
$mail -> Body = $js_output_email;
$mail -> AddAddress($admin_email_address, $admin_name);
$mail -> Send();
$mail -> ClearAddresses();
}
?>
|
Advertisement
| Hall of Fame |