Methods summary
public
|
|
public static
|
|
public static
|
|
public static
|
#
delete_variation( INT $cta_id, INT $vid )
Deletes variation for a call to action
Deletes variation for a call to action
Parameters
- $cta_id
- id of call to action
- $vid
- id of variation to delete
|
public static
|
#
pause_variation( INT $cta_id, INT $vid )
Pauses variation for a call to action
Pauses variation for a call to action
Parameters
- $cta_id
- id of call to action
- $vid
- id of variation to delete
|
public static
|
#
play_variation( INT $cta_id, INT $vid )
Activations variation for a call to action
Activations variation for a call to action
Parameters
- $cta_id
- id of call to action
- $vid
- id of variation to play
|
public static
|
#
set_variation_status( INT $cta_id, INT $vid, STRING $status = 'play' )
Sets the variation status to a custom status
Sets the variation status to a custom status
Parameters
- $cta_id
- id of call to action
- $vid
- id of variation to delete
- $status
- custom status
|
public static
|
|
public static
|
#
get_variations( INT $cta_id, INT $vid = null )
Returns array of variation data given a call to action id
Returns array of variation data given a call to action id
Parameters
- $cta_id
- id of call to action
- $vid
- id of specific variation
Returns
ARRAY of variation data
|
public static
|
#
get_variation_status( INT $cta_id, INT $vid = null )
Returns the status of a variation given cta_id and vid
Returns the status of a variation given cta_id and vid
Parameters
- $cta_id
- id of call to action
- $vid
- variation id of call to action
Returns
STRING status
|
public static
|
#
get_variation_permalink( INT $cta_id, INT $vid = null )
Returns the permalink of a variation given cta_id and vid
Returns the permalink of a variation given cta_id and vid
Parameters
- $cta_id
- id of call to action
- $vid
- variation id of call to action
Returns
STRING permalink
|
public static
|
#
update_variations( INT $cta_id, variations $variations )
Updates 'wp-cta-variations' meta key with json object
Updates 'wp-cta-variations' meta key with json object
Parameters
- $cta_id
- id of call to action
- $variations
- of variation data
|
public static
ARRAY
|
#
get_variation_meta( INT $cta_id, INT $vid )
Returns array of variation specific meta data
Returns array of variation specific meta data
Parameters
- $cta_id
- ID of call to action
- $vid
- ID of variation belonging to call to action
Returns
ARRAY $meta array of variation meta data
|
public static
STRING
|
#
get_variation_notes( INT $cta_id, INT $vid = null )
Gets the call to action variation notes
Gets the call to action variation notes
Parameters
- $cta_id
- id of call to action
- $vid
- variation id of call to action variation, will attempt to autodetect if left as null
Returns
STRING $notes variation notes.
|
public static
STRING
|
#
get_variation_custom_css( INT $cta_id, INT $vid = null )
Gets the call to action variation custom css
Gets the call to action variation custom css
Parameters
- $cta_id
- id of call to action
- $vid
- variation id of call to action variation, will attempt to autodetect if left as null
Returns
STRING $custom_css.
|
public static
STRING
|
#
get_variation_custom_js( INT $cta_id, INT $vid = null )
Gets the call to action variation custom js
Gets the call to action variation custom js
Parameters
- $cta_id
- id of call to action
- $vid
- variation id of call to action variation, will attempt to autodetect if left as null
Returns
STRING $custom_js.
|
public static
|
|
public static
|
|
public static
|
|
public static
|
|
public static
|
|
public static
STRING
|
#
get_screenshot_url( INT $cta_id, INT $vid = null )
Get Screenshot URL for Call to Action preview. If local environment show template thumbnail.
Get Screenshot URL for Call to Action preview. If local environment show template thumbnail.
Parameters
- $cta_id
- id if of call to action
- $vid
- id of variation belonging to call to action
Returns
STRING url of preview
|
public static
STRING
|
#
append_variation_id_to_url( link $link )
Appends current variation id onto a URL
Appends current variation id onto a URL
Parameters
- $link
- URL that param will be appended onto
Returns
STRING modified URL.
|
public static
STRING
|
#
vid_to_letter( INT $cta_id, INT $vid )
Discovers which alphabetic letter should be associated with a given cta's variation id.
Discovers which alphabetic letter should be associated with a given cta's variation id.
Parameters
- $cta_id
- id of call to action
- $vid
- id of variation belonging to call to action
Returns
STRING alphebit letter.
|
public static
INT
|
#
get_impressions( INT $cta_id, INT $vid )
Returns impression for given cta and variation id
Returns impression for given cta and variation id
Parameters
- $cta_id
- id of call to action
- $vid
- id of variation belonging to call to action
Returns
INT impression count
|
public static
|
#
set_impression_count( INT $cta_id, INT $vid, $count )
Manually sets conversion count for given cta id and variation id
Manually sets conversion count for given cta id and variation id
Parameters
- $cta_id
- id of call to action
- $vid
- id of variation belonging to call to action
- $count
|
public static
INT
|
#
get_conversions( INT $cta_id, INT $vid )
Returns total conversions for given cta and variation id
Returns total conversions for given cta and variation id
Parameters
- $cta_id
- id of call to action
- $vid
- id of variation belonging to call to action
Returns
INT total conversions count
|
public static
INT
|
#
get_clicks( INT $cta_id, INT $vid )
Returns clicks for given cta and variation id
Returns clicks for given cta and variation id
Parameters
- $cta_id
- id of call to action
- $vid
- id of variation belonging to call to action
Returns
INT click count
|
public static
INT
|
#
get_form_submissions( INT $cta_id, INT $vid )
Returns clicks for given cta and variation id
Returns clicks for given cta and variation id
Parameters
- $cta_id
- id of call to action
- $vid
- id of variation belonging to call to action
Returns
INT form submission count
|
public static
INT
|
#
get_conversion_rate( INT $cta_id, INT $vid )
Returns conversion rate for given cta and variation id
Returns conversion rate for given cta and variation id
Parameters
- $cta_id
- id of call to action
- $vid
- id of variation belonging to call to action
Returns
INT conversion rate
|
public static
|
#
set_conversion_count( INT $cta_id, INT $vid, $count )
Manually sets conversion count for given cta id and variation id
Manually sets conversion count for given cta id and variation id
Parameters
- $cta_id
- id of call to action
- $vid
- id of variation belonging to call to action
- $count
|