Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

Bing conversion code

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 05-16-2013, 09:18 AM
 
BritSteve BritSteve is offline
 

eXpert
  
Join Date: Apr 2006
Posts: 339
 

Question Bing conversion code

I am having trouble with the Bing conversion code not working as it should.

This is the code that I have been given by the company that deals with advertising for us. I have removed our account code. This is what is in the template file.

<!-- Bing Code for Purchase Conversion Page -->
<script type="text/javascript"> if (!window.mstag) mstag = {loadTag : function(){},time : (new Date()).getTime()};</script> <script id="mstag_tops" type="text/javascript" src="//flex.atdmt.com/mstag/site/ce168b15-1b45-479d-8757-18fcec513121/mstag.js"></script> <script type="text/javascript"> mstag.loadTag("analytics", {dedup:"1",domainId:"xxxxx",type:"1",revenue:"{$or der.order.total}",actionid:"131715"})</script> <noscript> <iframe src="//flex.atdmt.com/mstag/tag/ce168b15-1b45-479d-8757-18fcec513121/analytics.html?dedup=1&domainId=xxxxx&type=1&reven ue={$order.order.total}&actionid=131715" frameborder="0" scrolling="no" width="1" height="1" style="visibility:hidden;display:none"> </iframe> </noscript>

When I look at the source code on the thank you page, this is what is in there.

<!-- Bing Code for Purchase Conversion Page -->
<script type="text/javascript"> if (!window.mstag) mstag = ,time : (new Date()).getTime()};</script> <script id="mstag_tops" type="text/javascript" src="//flex.atdmt.com/mstag/site/ce168b15-1b45-479d-8757-18fcec513121/mstag.js"></script> <script type="text/javascript"> mstag.loadTag("analytics", ",actionid:"131715"})</script> <noscript> <iframe src="//flex.atdmt.com/mstag/tag/ce168b15-1b45-479d-8757-18fcec513121/analytics.html?dedup=1&domainId=xxxx&type=1&revenu e=38.49&actionid=131715" frameborder="0" scrolling="no" width="1" height="1" style="visibility:hidden;display:none"> </iframe> </noscript>

As you can see, there are differences, and the tracking code is not working. Maybe something is changing the code as it is output to the page?

Any ideas?

Thanks,

Steve
__________________
Version 4.1.8 & 4.1.9
ezcheckout4.1.x
cdseolinks2
product_metatags41x
shipping_per_product41x

http://www.earthsmagic.com
Reply With Quote
  #2  
Old 10-04-2015, 08:19 PM
 
Nishant Nishant is offline
 

Advanced Member
  
Join Date: Oct 2009
Posts: 39
 

Default Re: Bing conversion code

Hi,

Did you get it right ? the Bing Ad tracking code ?

I am having hard time to figure out the code.

Let me know.

thanks.
__________________
Various X-cart Versions...!!
Latest is X-cart 4.7.5
Reply With Quote
  #3  
Old 10-05-2015, 03:35 AM
  seyfin's Avatar 
seyfin seyfin is offline
 

X-Cart team
  
Join Date: May 2004
Posts: 1,223
 

Default Re: Bing conversion code

You should place your code between {literal} and {/literal} tags - it should help to solve the problem.
__________________
Sincerely yours,
Sergey Fomin
X-Cart team
Chief support group engineer

===

Check this out. Totally revamped X-Cart hosting
http://www.x-cart.com/hosting.html

Follow us:
https://twitter.com/x_cart / https://www.facebook.com/xcart / https://www.instagram.com/xcart
Reply With Quote
  #4  
Old 10-05-2015, 05:04 AM
  razortw's Avatar 
razortw razortw is offline
 

X-Cart team
  
Join Date: Feb 2015
Posts: 807
 

Default Re: Bing conversion code

This is happening because the Smarty templater interprets { and } symbols as its opening and closing tags.
So you should replace these symbols with {ldelim} and {rdelim} statements where it is necessary, or do like seyfin said, place the entire piece of code between {literal} and {/literal} tags.
__________________
Best regards,
Igor Pudovkin
X-Cart hosting team
Reply With Quote
  #5  
Old 01-25-2016, 02:31 PM
 
masada3336 masada3336 is offline
 

Senior Member
  
Join Date: Jan 2009
Posts: 115
 

Default Re: Bing conversion code

I can see my conversions, but I'm not getting the revenue variable. This is what I have on my 4.4.5 xcart:
Code:
{literal} <script>(function(w,d,t,r,u){var f,n,i;w[u]=w[u]||[],f=function(){var o={ti:"5077822"};o.q=w[u],w[u]=new UET(o),w[u].push("pageLoad")},n=d.createElement(t),n.src=r,n.async=1,n.onload=n.onreadystatechange=function(){var s=this.readyState;s&&s!=="loaded"&&s!=="complete"||(f(),n.onload=n.onreadystatechange=null)},i=d.getElementsByTagName(t)[0],i.parentNode.insertBefore(n,i)})(window,document,"script","//bat.bing.com/bat.js","uetq");</script> <noscript><img src="//bat.bing.com/action/0?ti=5077822&Ver=2" height="0" width="0" style="display:none; visibility: hidden;" /></noscript> {/literal}

Has anyone gotten Bing Revenue/UET code to work properly?
__________________
4.4.5 - with Customized Smart Template
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 09:22 PM.

   

 
X-Cart forums © 2001-2020