Editing Google Analytics eCommerce Javascript for Volusion
-
Does anyone know how to edit the ecommerce javascript with Volusion dynamic variables? I thought I did it correctly but none of the information got recorded in GA. It recorded that there was a transaction made but not info on the purchase price, order #, etc. This is the current code I am using:
NOTE: In Volusions customer support center they provided this information:
Where Order-Specific Information is Generated
Order-specific information can be generated by JavaScript on the OrderFinished.asp page within Volusion. On this page, two JavaScript arrays will be initialized that advanced users may need to be aware of. The arrays and their contents are as follow:
Order Array ContentsOrder[0] = Order ID
Order[1] = Unused
Order[2] = Payment Amount
Order[3] = Affiliate Commisionable Value
Order[4] = Sales Tax
Order[5] = Total Shipping Cost
Order[6] = Billing City
Order[7] = Billing State
Order[8] = Billing CountryOrderDetails Array Contents
OrderDetails[X][0] = Order ID
OrderDetails[X][1] = Order Detail ID
OrderDetails[X][2] = Product Code
OrderDetails[X][3] = Product Name
OrderDetails[X][4] = (unused)
OrderDetails[X][5] = Product Price
OrderDetails[X][6] = QuantityNote that in the above example, X refers to a line item number (beginning from zero). Note that there can be multiple Order Details arrays - one for each item contained within an order.
I'm a newbie at Analytics installation and could really use any help.
Thanks!
-
Thanks Gary! We've been looking everywhere and have tried several codes ourselves. Hoping this will work for our client's site.
-
Hi Jessica, The URLs below should help you out. http://guerrillo.com/add-google-analytics-volusion-store/ http://traffikco.com/blog/add-ecommerce-and-google-analytics-tracking-to-your-volusion-site/ It is not super technical stuff as long as you know how to copy paste it in my opinion. Best Regards, Gary
-
Hi Jessica, I work for Volusion and saw your question a couple of weeks ago. I sent you a private message but didn't hear back. There's a couple issues here.
As, Russ said above, you're referencing javascript variables inside single quotes, so the values for these variables are not 'seen'. If you take all references to Order[some digit]' out of the 'single quotes', google analytics should be able to 'see' the appropriate values. For example:
Where you have:
'Order[0]', // order ID - required
Should show like (no single quotes):
Order[0], // order ID - required
You would do this every time you see a reference to Order[some digit] and OrderDetails[x][some digit].
The second issue is a bit more complex. To send information about each product a customer may have ordered, you would need to loop through each set of products in the OrderDetails array. Because of the technical nature of the explanation, it would probably be simplest if you could privately message us your store url so we can make the updates for you.
Or, you could remove the existing google analytics you've implemented (general tracking and ecommerce tracking)...and use the recommended installation from the Volusion knowledge-base.
Hope this is helpful and please don't hesitate to reach out on a private message for more info.
Thank you.
-
From my first look, you are trying to call Javascript variables inside apostrophes. Should probably look like below, but I am just guessing.
_gaq.push(['_addItem',
OrderDetails[X][0],
OrderDetails[X][2],
OrderDetails[X][3],
'',
OrderDetails[X][5],
OrderDetails[X][6]
]);and the same would go for the other Order data.
Got a burning SEO question?
Subscribe to Moz Pro to gain full access to Q&A, answer questions, and ask your own.
Browse Questions
Explore more categories
-
Moz Tools
Chat with the community about the Moz tools.
-
SEO Tactics
Discuss the SEO process with fellow marketers
-
Community
Discuss industry events, jobs, and news!
-
Digital Marketing
Chat about tactics outside of SEO
-
Research & Trends
Dive into research and trends in the search industry.
-
Support
Connect on product support and feature requests.
Related Questions
-
Google Analytics Landing Page Report Discrepancy
I have noticed that when I run a landing page report and use the advanced option so I can view only the landing pages that include a particular string in the URL, have noticed that I in the report, the graph at the top will say one thing, but the data below says something else. For example, the graph for one particular search shows 200 Impressions, but the info below says 700 impressions and 610 clicks. Anyone seen anything similar or have any ideas why? Thanks! Craig
Reporting & Analytics | | TheCraig0 -
Google Analytics: Different stats for date range vs single month?
I've been scratching my head, chin, and you name it over this one. I have an advanced segment to remove bot traffic from my data. When I look at the Audience Overview data for a single month (let's say Aug). I am shown a session count. No problems here, however If I set the date range to (January - August). The august monthly stats is incorrect, much lower. What this means is that, if I export a CSV report from Jan-Aug, the data is wrong compared to individually recording a month. Anyone faced this? I've asked the question over at the Google Analytics technical section as well, but no answer P.S I even used the 'control the number of sessions used to calculate this report' tool but no luck.
Reporting & Analytics | | Bio-RadAbs0 -
Google Analytics Data
What tools can one use to audit a site to ensure that Google Analytics is capturing all the visits that we are getting? TIA Asif
Reporting & Analytics | | prsntsnh0 -
Where does the organic keyword information come from in Google Analytics?
I know that Google switch to all encrypted search, but I still show some keywords. Are those keywords that slipped through? Or are they all from Yahoo/Bing?
Reporting & Analytics | | EcommerceSite0 -
How to track affiliate ads on Google analytics
Hi Im new google analytics user, I would like to track affiliates ads (banner flow -javascript) on my website. How to set up goals to track affiliate ads? thanks.
Reporting & Analytics | | info_tipovanie-stavkovanie.com0 -
Google analytics
I updates all my google analytics accounts after the update and now i went to each campaign and it appears there is a problem and now if I reset it i loose history. Is this a glitch or a problem
Reporting & Analytics | | JAGlasvegas0 -
Regular Expressions in Google Analytics
I want to use the Google Analytics landing page reports to look at the bounce rate of top level pages excluding the homepage. So pages with urls: www.example.com/example Does anyone know a regular expression that will allow me to do this? Just to clarify I do not want to look at the bounce rate of the homepage or any pages deeper than www.example.com/example e.g: www.example.com/example/example www.example.com/example/example/example etc Thanks in advance
Reporting & Analytics | | CPLDistribution0