'
. __('Configure your AFS Analytics plugin in one click', 'afsanalytics') . '
'
. '';
$ret = $type == 'intro' ?
'
' . $logo :
$logo . '
';
return $ret . ''
. '
'
. '
'
. __('Or create a free account by clicking on "Create Free Account".', 'afsanalytics')
. ' '
. __('Would you wish to, you will be able to upgrade your free account to an advanced one at any time.', 'afsanalytics')
. '
'
. '
' . __('Create Free Account', 'afsanalytics') . '
'
. '
'
. '
'
. AFSA_Tools::render_js_data(
array('AFSA_site_infos' => AFSA_Account_Manager::get()->get_account_creation_params())
);
}
public static function redirect_on_account_linked()
{
if (!empty($_POST['afsa_linked_account_id'])) {
if (
empty($_POST['_wpnonce']) ||
! wp_verify_nonce($_POST['_wpnonce'], 'link_account')
) {
wp_nonce_ays('login');
}
$account_id = sanitize_text_field($_POST['afsa_linked_account_id']);
if (AFSA_Config::validate_account_id($account_id)) {
AFSA_Config::save_account_id($account_id);
$url = AFSA_Tools::build_url(
AFSA_Config::get_account_manager_url(),
array(
'afsa_action' => 'link_account',
'account_id' => $account_id,
)
);
AFSA_Tools::redirect($url);
}
}
}
public static function render_demo_form()
{
return '
'
. '
'
. '
'
. '
' . __('Live Demo', 'afsanalytics') . '
'
. '
'
. __('Experience the full power of AFS Analytics with our live demo. No Account required.', 'afsanalytics')
. '