• Resolved missterpan

    (@missterpan)


    Hi there

    My client did change the URL to be thanks landing page as they want their customer once the customer have purchases the items from the websites. Otherwise your plugin doesn’t work on this kind of method how can we approach on the tracking the purchase event by using current thanks url instead of this structure /order-received/.

    I see the document on GIThub but am not sure where should be taking care of this situation and if we were customized those PHP code when the plugin updated we have to redo it again right

    The page I need help with: [log in to see the link]

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author Torben Lundsgaard

    (@torbenlundsgaard)

    The purchase event fires on the order ‘order received’ page defined in WooCommerce settings > Advanced > Page setup > Order received

    In Google Tag Manager you can either create a trigger that matches all GA4 events or create a trigger based on the URL of the page or page type.

    Instead of creating a URL based trigger I recommemnd that you use the page type. Make sure that the setting i GTM Kit > Container > Page data > Page type is set to ON. The page type will then be available in the data layer and for the ‘order received’ it will alwaus be ?pageType: "order-received" regardless of the URL

    Thread Starter missterpan

    (@missterpan)

    Hi @torbenlundsgaard

    Thanks for the response meaning that either they changed the URL or not. They must include order-received into the thanks-page url right to be make sure that your plugin could be work

    Plugin Author Torben Lundsgaard

    (@torbenlundsgaard)

    Basing anything on a URL is always vulnerable to changes in the URL and that is why I always recommend using pageType for the trigger.

    Thread Starter missterpan

    (@missterpan)

    Thanks again, Otherwise what I mention is that the landing page hasn’t pushed the e-commerce data layer structure

    Plugin Author Torben Lundsgaard

    (@torbenlundsgaard)

    If the ckeckout has been customized it is possible that datalayer is not being pushed. GTM Kit pushes the eCommerce data layer if is_order_received_page() == true. You can test your confirmation page with this function and print som debug info to see if your confirmation page is registered correct.

    Plugin Author Torben Lundsgaard

    (@torbenlundsgaard)

    Closing this as resolved

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘purchase events for woocommerce with difference url’ is closed to new replies.