[ 'gpt-4-turbo' ], 2 => [ 'gpt-4-turbo', 'gpt-4.1' ], 3 => [ 'gpt-4-turbo', 'gpt-4.1', 'gpt-4o' ], 4 => [ 'gpt-4-turbo', 'gpt-4.1', 'gpt-4o' ], // Ultra-Premium (o3) removed ][$lvl] ?? [ 'gpt-4-turbo' ]; } /** * Render the settings page (two tabs: Site Key & SEO). * * @return void */ function aissp_render_settings_page() { /* Admin cache guard */ if ( function_exists('nocache_headers') ) { nocache_headers(); } $__aissp_build = 'aissp-settings-2025-09-02-GLOBAL-REMAINING-v3'; /* ---------------- Load current options ---------------- */ $opts = get_option( 'aissp_settings', [] ); $token = $opts['site_token'] ?? ''; $model = $opts['model_choice'] ?? 'gpt-4-turbo'; $tab = ( isset($_GET['tab']) && $_GET['tab']==='seo-settings' ) ? 'seo-settings' : 'site-key'; /* ===================================================== 1) FORM POSTS ===================================================== */ if ( isset( $_POST['aissp_action'] ) ) { if ( ! current_user_can( 'manage_options' ) ) { return; } $action = sanitize_key( wp_unslash( $_POST['aissp_action'] ) ); if ( $action === 'aissp_save_site_key' ) { check_admin_referer( 'aissp_save_site_key' ); $newKey = sanitize_text_field( wp_unslash( $_POST['site_token'] ?? '' ) ); $test = aissp_check_token_status( $newKey ); if ( ! empty( $test['error'] ) ) { echo '
Site Key Error: ' . esc_html( $test['error'] ) . '
Site Key saved.
Settings saved.
Generate AI SEO titles & meta descriptions in one click
Enter your Site Key below to connect your site with RankPilotAI.
Your site is connected to RankPilotAI.
Your current token usage across all sites.
Configure your AI model, prompts, indexing rules and slug behavior.