get_options_name()); if (!$old_options) { $new_options = $this->get_option_galogin(); $new_option['ga_poweredby'] = true; $this->save_option_galogin($new_option); } } protected function add_actions() { parent::add_actions(); add_action('wp_ajax_gal_drip_submitted', array($this, 'gal_drip_submitted')); } protected function ga_section_text_end() { ?>
' .'' .'
'
.''
.'Buy our premium Login plugin to revolutionize user management'
.'';
$adverts[] = '
'
.''
.'Try our Google Drive Embedder plugin'
.'
'
.''
.'Instantly turn WordPress into a corporate intranet with All-In-One Intranet'
.''.__('The Domain Control section is only applicable to the premium and enterprise versions of this plugin.', 'google-apps-login').'
'; echo ''; _e( 'In this basic version of the plugin, any existing WordPress account corresponding to a Google email address can authenticate via Google.', 'google-apps-login'); echo '
'; ?>In our professional plugins, you can specify your G Suite (Google Apps) domain name to obtain more powerful features.
Find out more about purchase options on our website: http://wp-glogin.com/
'; } protected function set_other_admin_notices() { global $pagenow; if (in_array($pagenow, array('users.php', 'user-new.php')) ) { $no_thanks = get_user_meta(get_current_user_id(), $this->get_options_name().'_no_thanks', true); if (!$no_thanks) { if (isset($_REQUEST['google_apps_login_action']) && $_REQUEST['google_apps_login_action']=='no_thanks') { $this->ga_said_no_thanks(null); } add_action('admin_notices', Array($this, 'ga_user_screen_upgrade_message')); if (is_multisite()) { add_action('network_admin_notices', Array($this, 'ga_user_screen_upgrade_message')); } } } } public function ga_said_no_thanks( $data ) { update_user_meta(get_current_user_id(), $this->get_options_name().'_no_thanks', true); wp_redirect( remove_query_arg( 'google_apps_login_action' ) ); exit; } public function ga_user_screen_upgrade_message() { $purchase_url = 'http://wp-glogin.com/glogin/?utm_source=User%20Pages&utm_medium=freemium&utm_campaign=Freemium'; $nothanks_url = add_query_arg( 'google_apps_login_action', 'no_thanks' ); echo ''; echo sprintf( __('Completely forget about WordPress user management - upgrade to Google Apps Login Premium or Enterprise to automatically sync users from your Google Apps domain', 'google-apps-login'), $purchase_url ); echo ' ' . __( 'Find out more', 'google-apps-login' ) . ''; echo ' ' . __( 'No Thanks', 'google-apps-login' ) . ''; echo '