Trial->Paid conversion tracking with GTM
* Added trial to paid conversion tracking with GTM * Removed WHMCS roundtrip from Showbuilder * Moved all Analytics code into common/GoogleAnalytics.php * Added a new Thank You page after plan changes to capture conversions * Added a ConversionTracking plugin to facilitate that * Also backported some minor staticBaseDir compatibility changes * Fixed a logic error in creating the baseDir
This commit is contained in:
parent
7b9efb988f
commit
3d03f837d2
11 changed files with 222 additions and 102 deletions
|
@ -824,7 +824,10 @@ class Application_Model_Preference
|
|||
|
||||
public static function SetPlanLevel($plan)
|
||||
{
|
||||
$oldPlanLevel = GetPlanLevel();
|
||||
self::setValue("plan_level", $plan);
|
||||
//We save the old plan level temporarily to facilitate conversion tracking
|
||||
self::setValue("old_plan_level", $oldPlanLevel);
|
||||
}
|
||||
|
||||
public static function GetPlanLevel()
|
||||
|
@ -837,6 +840,19 @@ class Application_Model_Preference
|
|||
return $plan;
|
||||
}
|
||||
|
||||
public static function GetOldPlanLevel()
|
||||
{
|
||||
$oldPlan = self::getValue("old_plan_level");
|
||||
return $oldPlan;
|
||||
}
|
||||
|
||||
/** Clearing the old plan level indicates a change in your plan has been tracked (Google Analytics) */
|
||||
public static function ClearOldPlanLevel()
|
||||
{
|
||||
self::setValue("old_plan_level", '');
|
||||
}
|
||||
|
||||
|
||||
public static function SetTrialEndingDate($date)
|
||||
{
|
||||
self::setValue("trial_end_date", $date);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue