So far, all we have tracked is page views. Very useful to be sure, but most managers and owners love their reports. On the Thank You page, we should include some simple e-commerce tracking. Again, because of jQuery Mobile's Ajax-based navigation system, we'll need to tweak the default examples just a hair to make it work perfectly with jQM.
Here is the full code for the Thank You page (thankyou.php
) with e-commerce tracking set to only run once the page is shown:
<!DOCTYPE html> <html> <?php $documentTitle = "Menu | Nicky's Pizza"; $headerLeftHref = "index.php"; $headerLeftLinkText = "Home"; $headerLeftIcon = "home"; $headerRightHref = "tel:8165077438"; $headerRightLinkText = "Call"; $headerRightIcon = "grid"; $fullSiteLinkHref = "/index.php"; ?> <head> <?php include("includes/meta.php"); ?> </head> <body> <div data-role="page" id="orderthankyou"> <?php $headerTitle...