Ask your WordPress questions! Pay money and get answers fast! (more info)

Add UnBounce tracking code to WooCommerce Thank You Page WordPress

  • SOLVED

I need to add the code shown here:
http://support.unbounce.com/entries/334187-External-conversion-tracking

To my WooCommerce "Thank You" page, that customers get sent to, after a successful sale.
http://novelconcept.org/checkout/order-received/

Not entirely sure how to add the code, since Wordpress doesn't really like adding code on pages.

Answers (2)

2013-07-13

Kyle answers:

Woocommerce allows you to override the default templates by creating a copy inside your theme folder. Once you create the copy you can insert a function to add the appropriate code to the page.


Kyle comments:

So create a folder called 'woocommerce' inside your theme

Inside that folder create another folder called 'checkout'

Copy the file thankyou.php file from /wp-content/plugins/woocommerce/templates/checkout/ folder to your new 'checkout' folder in your theme


Kyle comments:

Once you do that you can add your code to the new thankyou.php file. This is what it could look like if you want to just insert it with the page content: http://pastie.org/8137912

Although, many themes have an extra hook for right before the closing </body> tag, which is the ideal place to put the code. If yours does you can insert your code with a function on the template.

2013-07-13

isp_charlie answers:

i can help with informations wich you sent me yesterday?


philipzeplin comments:

Sure, that would be awesome!


isp_charlie comments:

Done.


philipzeplin comments:

Checked, looks correct! Thanks!