natasha21 Posted March 11, 2009 Share Posted March 11, 2009 Has anyone been able to implement this? This is the code that they provided OSCommerce Copy & Paste Code: // *** Changes made to following query and array assignment for Jellyfish Tracking $products_query = tep_db_query("select products_id, products_name, products_model, products_price, products_quantity from " . TABLE_ORDERS_PRODUCTS . " where orders_id = '" . (int)$orders['orders_id'] . "' order by products_name"); while ($products = tep_db_fetch_array($products_query)) { $products_array[] = array('id' => $products['products_id'], 'text' => $products['products_name'], 'product_id' => $products['products_model'], 'price' => $products['products_price'], 'quantity' => $products['products_quantity']); } // *** End Changes <!-- Jellyfish Order Tracking--> <script language="JavaScript"> <!-- var jf_merchant_id = 'ZW5ORmNvbEpIg'; // Provided by Jellyfish var jf_merchant_order_num = '<?php echo $order_id; ?>'; var jf_purchased_items = new Array(); // Add cart items <?php foreach($products_array as $item) { ?> var jf_item = new Object(); jf_item.mpi = "<?php echo $item['product_id']; ?>"; jf_item.price = <?php echo $item['price']; ?>; jf_item.quantity = <?php echo $item['quantity']; ?>; jf_purchased_items.push(jf_item); <?php } ?> //--> </script> <script language="JavaScript" src="https://www.jellyfish.com/javascripts/1x1tracking.js"> </script> <!-- End Jellyfish Order Tracking --> I've tried adding it to checkout success and process but it doesn't work any ideas are appreciated? does any one think it has to be split into 2, the javascript and the array? thanks soo much! Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.