Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
integration:foxycart:google_adwords [2019/10/11 04:04] – [Step 2: Customise the Adwords code] adam | integration:foxycart:google_adwords [2021/06/10 15:27] (current) – [Step 2: Install Adwords Tag] adam | ||
---|---|---|---|
Line 23: | Line 23: | ||
===== Installation ===== | ===== Installation ===== | ||
- | ==== Step 1: Get your Google | + | ==== Step 1: Create |
Follow the steps [[https:// | Follow the steps [[https:// | ||
Line 29: | Line 29: | ||
Once you complete the steps, you'll be offered choices on how you want to set up the tag. Select " | Once you complete the steps, you'll be offered choices on how you want to set up the tag. Select " | ||
- | This will provide you with some instructions for installing the Global Site Tag first off. Complete that section for your needs. Unless you've already included the Global Site Tag within your Foxy templates or configuration, | + | ==== Step 2: Install Adwords |
+ | === Global Site Tag === | ||
+ | This will provide you with some instructions for installing the Global Site Tag first off. Complete that section for your needs. Unless you've already included the Global Site Tag within your Foxy templates or configuration, | ||
+ | |||
+ | Copy the code shown to you based on your selection into the " | ||
+ | |||
+ | === Event Snippet === | ||
In the next section for the Event Snippet, leave the default selection as Page Load. Copy the code shown here into the " | In the next section for the Event Snippet, leave the default selection as Page Load. Copy the code shown here into the " | ||
- | < | + | < |
<!-- Event snippet for Test Ecommerce conversion page --> | <!-- Event snippet for Test Ecommerce conversion page --> | ||
< | < | ||
Line 45: | Line 51: | ||
</ | </ | ||
- | Modify the script to update the '' | + | Modify the script to update the '' |
<code javascript> | <code javascript> | ||
+ | if (FC.json.first_receipt_display && !FC.json.is_updateinfo && !FC.json.is_subscription_cancel) { | ||
+ | // gtag event code here | ||
+ | } | ||
+ | </ | ||
+ | |||
+ | The resulting snippet should look something like this: | ||
+ | |||
+ | <code html> | ||
<!-- Event snippet for Test Ecommerce conversion page --> | <!-- Event snippet for Test Ecommerce conversion page --> | ||
< | < | ||
- | if (FC.json.first_receipt_display) { | + | if (FC.json.first_receipt_display |
gtag(' | gtag(' | ||
' | ' | ||
Line 66: | Line 80: | ||
- | ==== Step 3: Add the code to your FoxyCart store configuration ==== | ||
- | Navigate to your store' |