| @@ -38,14 +38,14 @@ | ||
| 38 | 38 | <span class="dashicons dashicons-warning"></span> |
| 39 | 39 | <?php _e( 'Not Connected', 'wpforo' ); ?> |
| 40 | 40 | </div> |
| 41 | 41 | |
| 42 | - <p class="wpforo-ai-description"> | |
| 42 | + <p class="wpforo-ai-description" style="display: none;"> | |
| 43 | 43 | <?php _e( 'Connect your forum to wpForo AI to unlock powerful AI features including semantic search, content creation, moderation, and intelligent assistance.', 'wpforo' ); ?> |
| 44 | 44 | </p> |
| 45 | 45 | |
| 46 | 46 | <div class="wpforo-ai-callout"> |
| 47 | - <strong><?php _e( 'Start with 500 FREE credits! Generate your API key in one click and activate AI features!', 'wpforo' ); ?></strong> | |
| 47 | + <strong><?php _e( 'Start with 500 FREE credits, then subscribe to an AI Plan whenever you\'re ready! Activate AI features in one click!', 'wpforo' ); ?></strong> | |
| 48 | 48 | </div> |
| 49 | 49 | |
| 50 | 50 | <?php if ( $block_localhost ) : ?> |
| 51 | 51 | <div class="wpforo-ai-localhost-warning"> |
| @@ -53,9 +53,9 @@ | ||
| 53 | 53 | <?php _e( 'API key generation is only available for live websites. Please deploy your site to a public domain to connect to wpForo AI.', 'wpforo' ); ?> |
| 54 | 54 | </div> |
| 55 | 55 | <button type="button" class="button button-primary button-hero" disabled> |
| 56 | 56 | <span class="dashicons dashicons-admin-plugins" style="vertical-align: sub;"></span> |
| 57 | - <?php _e( 'Generate API Key & Connect', 'wpforo' ); ?> | |
| 57 | + <?php _e( 'Connect to wpForo AI Features', 'wpforo' ); ?> | |
| 58 | 58 | </button> |
| 59 | 59 | <?php else : ?> |
| 60 | 60 | <form method="post" action="" id="wpforo-ai-connect-form"> |
| 61 | 61 | <?php wp_nonce_field( 'wpforo_ai_connect' ); ?> |
| @@ -70,9 +70,9 @@ | ||
| 70 | 70 | printf( |
| 71 | 71 | __( 'I have read and agree to the %1$s and %2$s. I understand that my forum content will be processed by %3$s service as described in these documents.', 'wpforo' ), |
| 72 | 72 | '<a href="#" class="wpforo-ai-legal-link" data-document="terms" style="text-decoration: none;">' . __( 'Terms of Service', 'wpforo' ) . '</a>', |
| 73 | 73 | '<a href="#" class="wpforo-ai-legal-link" data-document="privacy" style="text-decoration: none;">' . __( 'Privacy Policy', 'wpforo' ) . '</a>', |
| 74 | - '<a href="https://v3.wpforo.com/gvectors-ai/" target="_blank" style="text-decoration: none;">' . __( 'gVectors AI', 'wpforo' ) . '</a>', | |
| 74 | + '<a href="https://wpforo.com/gvectors-ai/" target="_blank" style="text-decoration: none;">' . __( 'gVectors AI', 'wpforo' ) . '</a>', | |
| 75 | 75 | ); |
| 76 | 76 | ?> |
| 77 | 77 | </span> |
| 78 | 78 | </label> |
| @@ -79,9 +79,9 @@ | ||
| 79 | 79 | </div> |
| 80 | 80 | |
| 81 | 81 | <button type="submit" class="button button-primary button-hero" id="wpforo-ai-connect-btn"> |
| 82 | 82 | <span class="dashicons dashicons-admin-plugins" style="vertical-align: sub;"></span> |
| 83 | - <?php _e( 'Generate API Key & Connect', 'wpforo' ); ?> | |
| 83 | + <?php _e( 'Connect to wpForo AI Features', 'wpforo' ); ?> | |
| 84 | 84 | </button> |
| 85 | 85 | </form> |
| 86 | 86 | <?php endif; ?> |
| 87 | 87 | |
| @@ -107,8 +107,14 @@ | ||
| 107 | 107 | </div> |
| 108 | 108 | </div> |
| 109 | 109 | </div> |
| 110 | 110 | |
| 111 | + <!-- Getting Started Steps Box --> | |
| 112 | + <?php wpforo_ai_render_getting_started_steps( false ); ?> | |
| 113 | + | |
| 114 | + <!-- Video Tutorials Box --> | |
| 115 | + <?php wpforo_ai_render_video_tutorials(); ?> | |
| 116 | + | |
| 111 | 117 | <!-- Features Preview Box --> |
| 112 | 118 | <div class="wpforo-ai-box wpforo-ai-features-preview-box"> |
| 113 | 119 | <div class="wpforo-ai-box-header"> |
| 114 | 120 | <h2><?php _e( 'wpForo AI Features', 'wpforo' ); ?></h2> |
| @@ -190,8 +196,11 @@ | ||
| 190 | 196 | </div> |
| 191 | 197 | </div> |
| 192 | 198 | </div> |
| 193 | 199 | |
| 200 | + <!-- Video Tutorials Box --> | |
| 201 | + <?php wpforo_ai_render_video_tutorials(); ?> | |
| 202 | + | |
| 194 | 203 | <!-- Features Preview Box --> |
| 195 | 204 | <div class="wpforo-ai-box wpforo-ai-features-preview-box"> |
| 196 | 205 | <div class="wpforo-ai-box-header"> |
| 197 | 206 | <h2><?php _e( 'Available After Activation', 'wpforo' ); ?></h2> |
| @@ -244,9 +253,9 @@ | ||
| 244 | 253 | <span class="dashicons dashicons-info"></span> |
| 245 | 254 | <?php |
| 246 | 255 | printf( |
| 247 | 256 | __( 'Please %s if you believe this is an error or if you need assistance reactivating your account.', 'wpforo' ), |
| 248 | - '<a href="https://v3.wpforo.com/login-register/?tab=login" target="_blank">' . __( 'open a support ticket', 'wpforo' ) . '</a>' | |
| 257 | + '<a href="https://wpforo.com/login-register/?tab=login" target="_blank">' . __( 'open a support ticket', 'wpforo' ) . '</a>' | |
| 249 | 258 | ); |
| 250 | 259 | ?> |
| 251 | 260 | </div> |
| 252 | 261 | |
| @@ -263,8 +272,11 @@ | ||
| 263 | 272 | </div> |
| 264 | 273 | </div> |
| 265 | 274 | </div> |
| 266 | 275 | |
| 276 | + <!-- Video Tutorials Box --> | |
| 277 | + <?php wpforo_ai_render_video_tutorials(); ?> | |
| 278 | + | |
| 267 | 279 | <!-- Features Preview Box (disabled state) --> |
| 268 | 280 | <div class="wpforo-ai-box wpforo-ai-features-preview-box" style="opacity: 0.6;"> |
| 269 | 281 | <div class="wpforo-ai-box-header"> |
| 270 | 282 | <h2><?php _e( 'Features Unavailable', 'wpforo' ); ?></h2> |
| @@ -576,9 +588,9 @@ | ||
| 576 | 588 | <div class="wpforo-ai-actions"> |
| 577 | 589 | <?php if ( $is_free_trial ) : ?> |
| 578 | 590 | <button type="button" class="button button-primary button-large" onclick="document.getElementById('wpforo-ai-plans').scrollIntoView({ behavior: 'smooth' })"> |
| 579 | 591 | <span class="dashicons dashicons-cart"></span> |
| 580 | - <?php _e( 'Upgrade Now / View Plans', 'wpforo' ); ?> | |
| 592 | + <?php _e( 'Upgrade Now / View Subscription Plans', 'wpforo' ); ?> | |
| 581 | 593 | </button> |
| 582 | 594 | <?php else : ?> |
| 583 | 595 | <?php foreach ( $payment_providers as $provider ) : ?> |
| 584 | 596 | <a href="<?php echo esc_url( wpforo_ai_get_manage_subscription_url( $provider ) ); ?>" class="button button-secondary wpf-manage-subscription wpf-provider-<?php echo esc_attr( $provider ); ?>" target="_blank"> |
| @@ -596,8 +608,14 @@ | ||
| 596 | 608 | </div> |
| 597 | 609 | </div> |
| 598 | 610 | </div> |
| 599 | 611 | |
| 612 | + <!-- Getting Started Steps Box --> | |
| 613 | + <?php wpforo_ai_render_getting_started_steps(); ?> | |
| 614 | + | |
| 615 | + <!-- Video Tutorials Box --> | |
| 616 | + <?php wpforo_ai_render_video_tutorials(); ?> | |
| 617 | + | |
| 600 | 618 | <!-- Available Features Box --> |
| 601 | 619 | <div class="wpforo-ai-box wpforo-ai-features-box"> |
| 602 | 620 | <div class="wpforo-ai-box-header"> |
| 603 | 621 | <h2><?php echo $is_free_trial ? __( 'Available AI Features', 'wpforo' ) : __( 'Active AI Features', 'wpforo' ); ?></h2> |
| @@ -759,9 +777,9 @@ | ||
| 759 | 777 | |
| 760 | 778 | <div class="wpforo-ai-error-actions"> |
| 761 | 779 | <button type="button" class="button button-primary button-large" onclick="document.getElementById('wpforo-ai-plans').scrollIntoView({ behavior: 'smooth' })"> |
| 762 | 780 | <span class="dashicons dashicons-cart"></span> |
| 763 | - <?php _e( 'Upgrade Now / View Plans', 'wpforo' ); ?> | |
| 781 | + <?php _e( 'Upgrade Now / View Subscription Plans', 'wpforo' ); ?> | |
| 764 | 782 | </button> |
| 765 | 783 | |
| 766 | 784 | <form method="post" action="" style="display: inline;"> |
| 767 | 785 | <?php wp_nonce_field( 'wpforo_ai_refresh_status' ); ?> |
| @@ -777,9 +795,9 @@ | ||
| 777 | 795 | <p style="color: #666; font-size: 13px;"> |
| 778 | 796 | <?php |
| 779 | 797 | printf( |
| 780 | 798 | __( 'Need help? %s', 'wpforo' ), |
| 781 | - '<a href="https://v3.wpforo.com/login-register/?tab=login" target="_blank">' . __( 'Open Support Ticket', 'wpforo' ) . '</a>' | |
| 799 | + '<a href="https://wpforo.com/login-register/?tab=login" target="_blank">' . __( 'Open Support Ticket', 'wpforo' ) . '</a>' | |
| 782 | 800 | ); |
| 783 | 801 | ?> |
| 784 | 802 | </p> |
| 785 | 803 | </div> |
| @@ -785,8 +803,11 @@ | ||
| 785 | 803 | </div> |
| 786 | 804 | </div> |
| 787 | 805 | </div> |
| 788 | 806 | |
| 807 | + <!-- Video Tutorials Box --> | |
| 808 | + <?php wpforo_ai_render_video_tutorials(); ?> | |
| 809 | + | |
| 789 | 810 | <!-- Plans Section for expired users --> |
| 790 | 811 | <div id="wpforo-ai-plans" class="wpforo-ai-box" style="margin-top: 20px;"> |
| 791 | 812 | <div class="wpforo-ai-box-header"> |
| 792 | 813 | <h2><?php _e( 'Available Plans', 'wpforo' ); ?></h2> |
| @@ -885,9 +906,9 @@ | ||
| 885 | 906 | <p style="color: #666; font-size: 13px;"> |
| 886 | 907 | <?php |
| 887 | 908 | printf( |
| 888 | 909 | __( 'Need help? %s', 'wpforo' ), |
| 889 | - '<a href="https://v3.wpforo.com/login-register/?tab=login" target="_blank">' . __( 'Open Support Ticket', 'wpforo' ) . '</a>' | |
| 910 | + '<a href="https://wpforo.com/login-register/?tab=login" target="_blank">' . __( 'Open Support Ticket', 'wpforo' ) . '</a>' | |
| 890 | 911 | ); |
| 891 | 912 | ?> |
| 892 | 913 | </p> |
| 893 | 914 | </div> |
| @@ -893,8 +914,11 @@ | ||
| 893 | 914 | </div> |
| 894 | 915 | </div> |
| 895 | 916 | </div> |
| 896 | 917 | |
| 918 | + <!-- Video Tutorials Box --> | |
| 919 | + <?php wpforo_ai_render_video_tutorials(); ?> | |
| 920 | + | |
| 897 | 921 | <!-- Plans Section --> |
| 898 | 922 | <div id="wpforo-ai-plans" class="wpforo-ai-box" style="margin-top: 20px;"> |
| 899 | 923 | <div class="wpforo-ai-box-header"> |
| 900 | 924 | <h2><?php _e( 'Available Plans', 'wpforo' ); ?></h2> |
| @@ -1001,9 +1025,9 @@ | ||
| 1001 | 1025 | <p> |
| 1002 | 1026 | <?php |
| 1003 | 1027 | printf( |
| 1004 | 1028 | __( 'Need help? %s', 'wpforo' ), |
| 1005 | - '<a href="https://v3.wpforo.com/login-register/?tab=login" target="_blank">' . __( 'Open Support Ticket', 'wpforo' ) . '</a>' | |
| 1029 | + '<a href="https://wpforo.com/login-register/?tab=login" target="_blank">' . __( 'Open Support Ticket', 'wpforo' ) . '</a>' | |
| 1006 | 1030 | ); |
| 1007 | 1031 | ?> |
| 1008 | 1032 | </p> |
| 1009 | 1033 | </div> |
| @@ -1204,8 +1228,342 @@ | ||
| 1204 | 1228 | echo '</ul>'; |
| 1205 | 1229 | } |
| 1206 | 1230 | |
| 1207 | 1231 | /** |
| 1232 | + * Render Getting Started Steps Box | |
| 1233 | + * | |
| 1234 | + * Displays a visual progress indicator showing the steps to use wpForo AI. | |
| 1235 | + * First step (Connect) is marked as completed when connected, shows "1" when not. | |
| 1236 | + * | |
| 1237 | + * @param bool $is_connected Whether the user is connected to AI services | |
| 1238 | + */ | |
| 1239 | +function wpforo_ai_render_getting_started_steps( $is_connected = true ) { | |
| 1240 | + // Build URLs for each step | |
| 1241 | + $indexing_url = admin_url( 'admin.php?page=wpforo-ai&tab=rag_indexing' ); | |
| 1242 | + $settings_url = admin_url( 'admin.php?page=wpforo-settings&wpf_tab=ai' ); | |
| 1243 | + $spam_url = admin_url( 'admin.php?page=wpforo-settings&wpf_tab=ai#moderation_spam' ); | |
| 1244 | + $forum_url = wpforo_home_url(); | |
| 1245 | + $logs_url = admin_url( 'admin.php?page=wpforo-ai&tab=ai_logs' ); | |
| 1246 | + ?> | |
| 1247 | + <div class="wpforo-ai-box wpforo-ai-getting-started-box"> | |
| 1248 | + <div class="wpforo-ai-box-header"> | |
| 1249 | + <h2><?php _e( 'Getting Started with wpForo AI', 'wpforo' ); ?></h2> | |
| 1250 | + </div> | |
| 1251 | + <div class="wpforo-ai-box-body"> | |
| 1252 | + <div class="wpforo-ai-steps"> | |
| 1253 | + <div class="wpforo-ai-step <?php echo $is_connected ? 'completed' : ''; ?>"> | |
| 1254 | + <div class="wpforo-ai-step-icon"> | |
| 1255 | + <?php if ( $is_connected ) : ?> | |
| 1256 | + <span class="dashicons dashicons-yes-alt"></span> | |
| 1257 | + <?php else : ?> | |
| 1258 | + <span class="wpforo-ai-step-number">1</span> | |
| 1259 | + <?php endif; ?> | |
| 1260 | + </div> | |
| 1261 | + <div class="wpforo-ai-step-label"><?php _e( 'Connect wpForo AI', 'wpforo' ); ?></div> | |
| 1262 | + </div> | |
| 1263 | + <div class="wpforo-ai-step-connector"></div> | |
| 1264 | + <?php if ( $is_connected ) : ?> | |
| 1265 | + <a href="<?php echo esc_url( $indexing_url ); ?>" class="wpforo-ai-step"> | |
| 1266 | + <?php else : ?> | |
| 1267 | + <div class="wpforo-ai-step"> | |
| 1268 | + <?php endif; ?> | |
| 1269 | + <div class="wpforo-ai-step-icon"> | |
| 1270 | + <span class="wpforo-ai-step-number">2</span> | |
| 1271 | + </div> | |
| 1272 | + <div class="wpforo-ai-step-label" style="color: rgb(214, 39, 224);"><?php _e( 'Index Forum Content', 'wpforo' ); ?></div> | |
| 1273 | + <?php echo $is_connected ? '</a>' : '</div>'; ?> | |
| 1274 | + <div class="wpforo-ai-step-connector"></div> | |
| 1275 | + <?php if ( $is_connected ) : ?> | |
| 1276 | + <a href="<?php echo esc_url( $settings_url ); ?>" class="wpforo-ai-step"> | |
| 1277 | + <?php else : ?> | |
| 1278 | + <div class="wpforo-ai-step"> | |
| 1279 | + <?php endif; ?> | |
| 1280 | + <div class="wpforo-ai-step-icon"> | |
| 1281 | + <span class="wpforo-ai-step-number">3</span> | |
| 1282 | + </div> | |
| 1283 | + <div class="wpforo-ai-step-label"><?php _e( 'Manage AI Features', 'wpforo' ); ?></div> | |
| 1284 | + <?php echo $is_connected ? '</a>' : '</div>'; ?> | |
| 1285 | + <div class="wpforo-ai-step-connector"></div> | |
| 1286 | + <?php if ( $is_connected ) : ?> | |
| 1287 | + <a href="<?php echo esc_url( $forum_url ); ?>" class="wpforo-ai-step" target="_blank"> | |
| 1288 | + <?php else : ?> | |
| 1289 | + <div class="wpforo-ai-step"> | |
| 1290 | + <?php endif; ?> | |
| 1291 | + <div class="wpforo-ai-step-icon"> | |
| 1292 | + <span class="wpforo-ai-step-number">4</span> | |
| 1293 | + </div> | |
| 1294 | + <div class="wpforo-ai-step-label"><?php _e( 'Use', 'wpforo' ); ?><br><?php _e( 'AI Features', 'wpforo' ); ?></div> | |
| 1295 | + <?php echo $is_connected ? '</a>' : '</div>'; ?> | |
| 1296 | + <div class="wpforo-ai-step-connector"></div> | |
| 1297 | + <?php if ( $is_connected ) : ?> | |
| 1298 | + <a href="<?php echo esc_url( $spam_url ); ?>" class="wpforo-ai-step"> | |
| 1299 | + <?php else : ?> | |
| 1300 | + <div class="wpforo-ai-step"> | |
| 1301 | + <?php endif; ?> | |
| 1302 | + <div class="wpforo-ai-step-icon"> | |
| 1303 | + <span class="wpforo-ai-step-number">5</span> | |
| 1304 | + </div> | |
| 1305 | + <div class="wpforo-ai-step-label"><?php _e( 'Enable AI Spam Protection', 'wpforo' ); ?></div> | |
| 1306 | + <?php echo $is_connected ? '</a>' : '</div>'; ?> | |
| 1307 | + <div class="wpforo-ai-step-connector"></div> | |
| 1308 | + <?php if ( $is_connected ) : ?> | |
| 1309 | + <a href="<?php echo esc_url( $logs_url ); ?>" class="wpforo-ai-step"> | |
| 1310 | + <?php else : ?> | |
| 1311 | + <div class="wpforo-ai-step"> | |
| 1312 | + <?php endif; ?> | |
| 1313 | + <div class="wpforo-ai-step-icon"> | |
| 1314 | + <span class="wpforo-ai-step-number">6</span> | |
| 1315 | + </div> | |
| 1316 | + <div class="wpforo-ai-step-label"><?php _e( 'Monitor AI Usage', 'wpforo' ); ?></div> | |
| 1317 | + <?php echo $is_connected ? '</a>' : '</div>'; ?> | |
| 1318 | + </div> | |
| 1319 | + <div class="wpforo-ai-privacy-note"> | |
| 1320 | + <p><span class="dashicons dashicons-shield" style="color: #0073aa;"></span> <strong><?php _e( 'Your Data Stays Yours', 'wpforo' ); ?></strong></p> | |
| 1321 | + <ul> | |
| 1322 | + <li><strong style="color: rgb(214, 39, 224);"><?php _e( 'Forum content indexing', 'wpforo' ); ?></strong> <?php _e( 'converts your forum content into mathematical vectors (embeddings) to power AI search and features.', 'wpforo' ); ?></li> | |
| 1323 | + <li><?php _e( 'Your data is never used to train AI models. We use pre-trained models from Amazon Bedrock.', 'wpforo' ); ?></li> | |
| 1324 | + <li><?php _e( 'By default your data embeddings are stored locally in your WordPress database.', 'wpforo' ); ?></li> | |
| 1325 | + </ul> | |
| 1326 | + </div> | |
| 1327 | + <div class="wpforo-ai-steps-cta"> | |
| 1328 | + <a href="https://wpforo.com/docs/wpforo-v3/ai-features/#getting-started" target="_blank" class="button button-primary button-hero"> | |
| 1329 | + <span class="dashicons dashicons-book" style="vertical-align: middle; margin-right: 5px;"></span> | |
| 1330 | + <?php _e( 'Read AI Features Documentation', 'wpforo' ); ?> | |
| 1331 | + </a> | |
| 1332 | + </div> | |
| 1333 | + </div> | |
| 1334 | + </div> | |
| 1335 | + <style> | |
| 1336 | + .wpforo-ai-privacy-note { | |
| 1337 | + background: #f0f7fc; | |
| 1338 | + border-left: 4px solid #0073aa; | |
| 1339 | + padding: 15px 20px; | |
| 1340 | + margin: 20px 0; | |
| 1341 | + border-radius: 0 4px 4px 0; | |
| 1342 | + } | |
| 1343 | + .wpforo-ai-privacy-note p { | |
| 1344 | + margin: 0 0 10px 0; | |
| 1345 | + font-size: 14px; | |
| 1346 | + } | |
| 1347 | + .wpforo-ai-privacy-note ul { | |
| 1348 | + margin: 0; | |
| 1349 | + padding-left: 20px; | |
| 1350 | + } | |
| 1351 | + .wpforo-ai-privacy-note li { | |
| 1352 | + margin-bottom: 5px; | |
| 1353 | + font-size: 13px; | |
| 1354 | + color: #444; | |
| 1355 | + } | |
| 1356 | + .wpforo-ai-getting-started-box { | |
| 1357 | + margin-bottom: 20px; | |
| 1358 | + } | |
| 1359 | + .wpforo-ai-steps-cta { | |
| 1360 | + text-align: center; | |
| 1361 | + margin-top: 10px; | |
| 1362 | + padding-top: 20px; | |
| 1363 | + border-top: 1px solid #e0e0e0; | |
| 1364 | + } | |
| 1365 | + .wpforo-ai-steps-cta .button-hero { | |
| 1366 | + font-size: 15px; | |
| 1367 | + padding: 10px 25px; | |
| 1368 | + height: auto; | |
| 1369 | + } | |
| 1370 | + .wpforo-ai-steps { | |
| 1371 | + display: flex; | |
| 1372 | + align-items: center; | |
| 1373 | + justify-content: center; | |
| 1374 | + padding: 30px 20px; | |
| 1375 | + gap: 0; | |
| 1376 | + } | |
| 1377 | + .wpforo-ai-step { | |
| 1378 | + display: flex; | |
| 1379 | + flex-direction: column; | |
| 1380 | + align-items: center; | |
| 1381 | + text-decoration: none; | |
| 1382 | + color: #1d2327; | |
| 1383 | + transition: transform 0.2s ease; | |
| 1384 | + } | |
| 1385 | + a.wpforo-ai-step:hover { | |
| 1386 | + transform: translateY(-3px); | |
| 1387 | + } | |
| 1388 | + a.wpforo-ai-step:hover .wpforo-ai-step-icon { | |
| 1389 | + background: #2271b1; | |
| 1390 | + color: #fff; | |
| 1391 | + border-color: #2271b1; | |
| 1392 | + } | |
| 1393 | + .wpforo-ai-step-icon { | |
| 1394 | + width: 50px; | |
| 1395 | + height: 50px; | |
| 1396 | + border-radius: 50%; | |
| 1397 | + background: #f0f0f1; | |
| 1398 | + border: 2px solid #c3c4c7; | |
| 1399 | + display: flex; | |
| 1400 | + align-items: center; | |
| 1401 | + justify-content: center; | |
| 1402 | + margin-bottom: 10px; | |
| 1403 | + transition: all 0.2s ease; | |
| 1404 | + } | |
| 1405 | + a.wpforo-ai-step .wpforo-ai-step-icon { | |
| 1406 | + background: #edfaef; | |
| 1407 | + border-color: #00a32a; | |
| 1408 | + } | |
| 1409 | + a.wpforo-ai-step .wpforo-ai-step-number { | |
| 1410 | + color: #00a32a; | |
| 1411 | + } | |
| 1412 | + .wpforo-ai-step.completed .wpforo-ai-step-icon { | |
| 1413 | + background: #00a32a; | |
| 1414 | + border-color: #00a32a; | |
| 1415 | + color: #fff; | |
| 1416 | + } | |
| 1417 | + .wpforo-ai-step.completed .wpforo-ai-step-icon .dashicons { | |
| 1418 | + font-size: 24px; | |
| 1419 | + width: 24px; | |
| 1420 | + height: 24px; | |
| 1421 | + } | |
| 1422 | + .wpforo-ai-step-number { | |
| 1423 | + font-size: 18px; | |
| 1424 | + font-weight: 600; | |
| 1425 | + color: #50575e; | |
| 1426 | + } | |
| 1427 | + a.wpforo-ai-step:hover .wpforo-ai-step-number { | |
| 1428 | + color: #fff; | |
| 1429 | + } | |
| 1430 | + .wpforo-ai-step-label { | |
| 1431 | + font-size: 13px; | |
| 1432 | + font-weight: 500; | |
| 1433 | + text-align: center; | |
| 1434 | + max-width: 100px; | |
| 1435 | + line-height: 1.3; | |
| 1436 | + } | |
| 1437 | + .wpforo-ai-step-connector { | |
| 1438 | + width: 40px; | |
| 1439 | + height: 2px; | |
| 1440 | + background: #c3c4c7; | |
| 1441 | + margin: 0 5px; | |
| 1442 | + margin-bottom: 30px; | |
| 1443 | + } | |
| 1444 | + @media (max-width: 900px) { | |
| 1445 | + .wpforo-ai-steps { | |
| 1446 | + flex-wrap: wrap; | |
| 1447 | + gap: 15px; | |
| 1448 | + } | |
| 1449 | + .wpforo-ai-step-connector { | |
| 1450 | + display: none; | |
| 1451 | + } | |
| 1452 | + } | |
| 1453 | + </style> | |
| 1454 | + <?php | |
| 1455 | +} | |
| 1456 | + | |
| 1457 | +/** | |
| 1458 | + * Render Video Tutorials Box | |
| 1459 | + * | |
| 1460 | + * Displays 3 YouTube video tutorials in a 3-column grid layout. | |
| 1461 | + * Shown on the AI Features overview page between connection status and features list. | |
| 1462 | + */ | |
| 1463 | +function wpforo_ai_render_video_tutorials() { | |
| 1464 | + $videos = [ | |
| 1465 | + [ | |
| 1466 | + 'url' => 'https://www.youtube.com/watch?v=ZmNEAYSWg8M', | |
| 1467 | + 'title' => __( 'wpForo AI Search', 'wpforo' ), | |
| 1468 | + ], | |
| 1469 | + [ | |
| 1470 | + 'url' => 'https://www.youtube.com/watch?v=Pq5BvlrkXwE', | |
| 1471 | + 'title' => __( 'wpForo AI Topic Summary', 'wpforo' ), | |
| 1472 | + ], | |
| 1473 | + [ | |
| 1474 | + 'url' => 'https://www.youtube.com/watch?v=2NmKtJO6miQ', | |
| 1475 | + 'title' => __( 'wpForo AI Translation', 'wpforo' ), | |
| 1476 | + ], | |
| 1477 | + ]; | |
| 1478 | + ?> | |
| 1479 | + <div class="wpforo-ai-box wpforo-ai-video-tutorials-box"> | |
| 1480 | + <div class="wpforo-ai-box-header"> | |
| 1481 | + <h2><?php _e( 'wpForo AI Features in Action', 'wpforo' ); ?></h2> | |
| 1482 | + </div> | |
| 1483 | + <div class="wpforo-ai-box-body"> | |
| 1484 | + <div class="wpforo-ai-videos-grid"> | |
| 1485 | + <?php foreach ( $videos as $video ) : ?> | |
| 1486 | + <div class="wpforo-ai-video-item"> | |
| 1487 | + <div class="wpforo-ai-video-wrapper"> | |
| 1488 | + <?php echo wp_oembed_get( $video['url'] ); ?> | |
| 1489 | + </div> | |
| 1490 | + <h4 class="wpforo-ai-video-title"><?php echo esc_html( $video['title'] ); ?></h4> | |
| 1491 | + </div> | |
| 1492 | + <?php endforeach; ?> | |
| 1493 | + </div> | |
| 1494 | + <div class="wpforo-ai-videos-cta"> | |
| 1495 | + <a href="https://wpforo.com/#ai-features" target="_blank" class="button button-primary button-hero"> | |
| 1496 | + <span class="dashicons dashicons-video-alt3" style="vertical-align: middle; margin-right: 5px;"></span> | |
| 1497 | + <?php _e( 'See All AI Features', 'wpforo' ); ?> | |
| 1498 | + </a> | |
| 1499 | + </div> | |
| 1500 | + </div> | |
| 1501 | + </div> | |
| 1502 | + <style> | |
| 1503 | + .wpforo-ai-video-tutorials-box { | |
| 1504 | + margin-bottom: 20px; | |
| 1505 | + } | |
| 1506 | + .wpforo-ai-videos-cta { | |
| 1507 | + text-align: center; | |
| 1508 | + margin-top: 20px; | |
| 1509 | + padding-top: 20px; | |
| 1510 | + border-top: 1px solid #e0e0e0; | |
| 1511 | + } | |
| 1512 | + .wpforo-ai-videos-cta .button-hero { | |
| 1513 | + font-size: 15px; | |
| 1514 | + padding: 10px 25px; | |
| 1515 | + height: auto; | |
| 1516 | + } | |
| 1517 | + .wpforo-ai-videos-grid { | |
| 1518 | + display: grid; | |
| 1519 | + grid-template-columns: repeat(3, 1fr); | |
| 1520 | + gap: 20px; | |
| 1521 | + } | |
| 1522 | + .wpforo-ai-video-item { | |
| 1523 | + background: #f9f9f9; | |
| 1524 | + border-radius: 8px; | |
| 1525 | + overflow: hidden; | |
| 1526 | + } | |
| 1527 | + .wpforo-ai-video-wrapper { | |
| 1528 | + position: relative; | |
| 1529 | + padding-bottom: 56.25%; | |
| 1530 | + height: 0; | |
| 1531 | + overflow: hidden; | |
| 1532 | + } | |
| 1533 | + .wpforo-ai-video-wrapper iframe { | |
| 1534 | + position: absolute; | |
| 1535 | + top: 0; | |
| 1536 | + left: 0; | |
| 1537 | + width: 100%; | |
| 1538 | + height: 100%; | |
| 1539 | + border-radius: 8px 8px 0 0; | |
| 1540 | + } | |
| 1541 | + .wpforo-ai-video-title { | |
| 1542 | + margin: 0; | |
| 1543 | + padding: 12px 15px; | |
| 1544 | + font-size: 14px; | |
| 1545 | + font-weight: 600; | |
| 1546 | + color: #1d2327; | |
| 1547 | + text-align: center; | |
| 1548 | + background: #fff; | |
| 1549 | + border-top: 1px solid #e0e0e0; | |
| 1550 | + } | |
| 1551 | + @media (max-width: 1200px) { | |
| 1552 | + .wpforo-ai-videos-grid { | |
| 1553 | + grid-template-columns: repeat(2, 1fr); | |
| 1554 | + } | |
| 1555 | + } | |
| 1556 | + @media (max-width: 782px) { | |
| 1557 | + .wpforo-ai-videos-grid { | |
| 1558 | + grid-template-columns: 1fr; | |
| 1559 | + } | |
| 1560 | + } | |
| 1561 | + </style> | |
| 1562 | + <?php | |
| 1563 | +} | |
| 1564 | + | |
| 1565 | +/** | |
| 1208 | 1566 | * Get all available features with metadata |
| 1209 | 1567 | * |
| 1210 | 1568 | * @return array Features array |
| 1211 | 1569 | */ |
| @@ -1592,9 +1950,9 @@ | ||
| 1592 | 1950 | $pricing = wpforo_ai_get_freemius_pricing(); |
| 1593 | 1951 | $plans = $pricing['plans']; |
| 1594 | 1952 | |
| 1595 | 1953 | ?> |
| 1596 | - <div class="wpforo-ai-callout"> | |
| 1954 | + <div class="wpforo-ai-callout" style="display: none;"> | |
| 1597 | 1955 | <span class="dashicons dashicons-info"></span> |
| 1598 | 1956 | <div> |
| 1599 | 1957 | <strong><?php _e( 'Credit-Based Pricing', 'wpforo' ); ?></strong> |
| 1600 | 1958 | <p><?php _e( 'Pay only for what you use with flexible credit-based pricing. Credits roll over month-to-month as long as you have an active subscription plan. Each plan allows credit accumulation up to one year of subscription plan credits. Start with 500 free credits, then choose a plan that fits your forum\'s activity level.', 'wpforo' ); ?><br><?php _e('You can select the quality of AI model for each feature individually: ', 'wpforo') ?></p> |
| @@ -1745,9 +2103,9 @@ | ||
| 1745 | 2103 | <small><?php printf( __( 'Renews %s', 'wpforo' ), esc_html( wpforo_ai_format_date( $renews_at ) ) ); ?></small> |
| 1746 | 2104 | <?php endif; ?> |
| 1747 | 2105 | </div> |
| 1748 | 2106 | <?php else : ?> |
| 1749 | - <a href="https://v3.wpforo.com/gvectors-ai/#gvai-contact" target="_blank" class="button button-secondary" style="padding: 5px 20px;"> | |
| 2107 | + <a href="https://wpforo.com/gvectors-ai/#gvai-contact" target="_blank" class="button button-secondary" style="padding: 5px 20px;"> | |
| 1750 | 2108 | <?php _e( 'Contact Us', 'wpforo' ) ?> |
| 1751 | 2109 | </a> |
| 1752 | 2110 | <?php endif; ?> |
| 1753 | 2111 | </td> |
| @@ -2111,9 +2469,9 @@ | ||
| 2111 | 2469 | <span class="dashicons dashicons-yes-alt"></span> |
| 2112 | 2470 | <?php _e( 'Active', 'wpforo' ); ?> |
| 2113 | 2471 | </div> |
| 2114 | 2472 | <?php else : ?> |
| 2115 | - <a href="https://v3.wpforo.com/gvectors-ai/#gvai-contact" target="_blank" class="button button-secondary" style="padding: 5px 20px;"> | |
| 2473 | + <a href="https://wpforo.com/gvectors-ai/#gvai-contact" target="_blank" class="button button-secondary" style="padding: 5px 20px;"> | |
| 2116 | 2474 | <?php _e( 'Contact Us', 'wpforo' ) ?> |
| 2117 | 2475 | </a> |
| 2118 | 2476 | <?php endif; ?> |
| 2119 | 2477 | </td> |