The Ultimate Guide to Coding CSE Conversion Scripts in Miva Merchant

Many of us rely on Comparison Shopping Engines such as Nextag, Pricegrabber, and the likes to drive targeted traffic to our websites. When advertising with comparison shopping engines (CSEs), it’s important to pay attention to your conversion rates to determine what’s working and what isn’t.

Most CSEs provide a conversion tracking mechanism directly. Typically, this is a bit of JavaScript code that you put on your completion page, which includes information such as the order number, products purchased, quantities, prices, and so forth. Each CSE’s code is unique to its platform, so your Miva Merchant developer may have to rework the same kind of information over and over to produce the different scripts necessary to track conversions across multiple engines.

To make it easier, we’re developing this page as a library of conversion script code for Miva Merchant. Typically you’d put these on your INVC (“invoice”) page somehow, either on the page itself, in its page header or footer, or in the global header or footer wrapped in an mvt:if statement that limits the code to the INVC screen. Personally, I like to put it on the INVC page footer because I rarely use it for anything else, so it’s easy to keep all of this code in that single spot.

Note: In each code snippet, I’ve replaced any identifying ids, such as merchant or account ids, with the string “11111″. Make sure to replace all of those instances with your own values!

Finally, some of these examples require some kind of “tool” module. Personally, I like the EmporiumPlus toolkit module, so that’s what’s shown below. If you use the PCINet Toolbelt module, or anything else similar, you will need to adjust the code accordingly.

CSEs are listed alphabetically. Conversion Tracking Code for Miva Merchant

This is my favorite code because of its elegant use of arrays. That won’t make a difference for most of you, but if  you’re a geek like me, notice how much easier it is to do this than to concatenate strings and so forth. As such, Toolkit isn’t required.

I’m missing one piece of data here that would be really nice to include – the category that the product belongs too. If you include that, you can track the ROI for entire categories. Miva Merchant lets you assign the same product to multiple categories, so traditionally there wasn’t an easy way to do this. Now that they’ve introduced a canonical category code for each product, this may be simpler…but I haven’t tried it yet.

Bizrate/Shopzilla Performance Tracking Code for Miva Merchant

Bizrate/Shopzilla doesn’t require the list of individual products, but you can send the total number of items. To do so I use Toolkit, which I’ll show below. But here’s the basic code without passing anything for the optional field units_ordered.

To calculate the units_ordered, you’d first need to decide if you want to pass over the number of line items or the total quantity. If someone orders 3 of item XYZ and 5 of item ABC, then there are two line items (XYZ and ABC), but a total quantity of 8 (3 of the first line item plus 5 of the second line item). Here’s the code for the number of line items (Toolkit required):

And here’s the code if you want to include the total quantity:

Bizrate Tracking and Survey Code for Miva Merchant

Bizrate also provides a popup or floating div that offers people the ability to complete a survey. This code takes some general information about the order, and you can also pass in item-specific data, but only for up to 5 items. Here’s the code: Conversion Tracking Code for Miva Merchant

This code is pretty simple – just the merchant id and the order total. No toolkit-type of module needed.

NexTag ROI Optimizer Code for Miva Merchant

NexTag requires you to send a list of products in the order, along with the quantities purchased. The code does not require Toolkit.


PriceGrabber Conversion Tracking Code for Miva Merchant

Whoowee. PriceGrabber does not make implementing this code easy in Miva! It’s a bunch of concatenated strings that require Toolkit to build. They also want additional information that’s not part of the standard product catalog, such as manufacturer, MPN, and UPC. In this example I’ve assumed all of this is loaded into custom fields called “manufacturer”, “mpn”, and “upc”. Adjust as needed. They are all optional but you’ll get better results if you provide more of the optional data. Conversion Tracking Code for Miva Merchant has a newer version of their ROI tracker that is much easier to implement in Miva Merchant…no Toolkit module required. As with above, we could also theoretically pass in the canonical category code, but that’s not shown here.

Other Comparison Shopping Engines

What other comparison shopping engines do you use? Which ones would you like to see included here? Leave a comment below and I’ll do my best to help. In the meantime feel free to tweet this post to all of your followers using the box below. We really appreciate it!