PluginProbe
SupportCandy – AI Customer Support Ticket System & Live Chatbot Agent / trunk
SupportCandy – AI Customer Support Ticket System & Live Chatbot Agent vtrunk
3.5.3 3.5.2 3.5.1 3.4.9 3.5.0 3.4.8 3.4.7 trunk 2.3.1 3.3.6 3.3.7 3.3.8 3.3.9 3.4.0 3.4.1 3.4.2 3.4.3 3.4.4 3.4.5 3.4.6
supportcandy / includes / admin / ai-chatbot / index.php

index.php in SupportCandy – AI Customer Support Ticket System & Live Chatbot Agent trunk, at includes/admin/ai-chatbot/index.php

41 lines 1.1 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 $acb_settings = get_option( 'wpsc-ps-acb-chatbot-settings', array() );
3
4 // Load includes (settings, admin & cron hooks) so the settings UI stays reachable regardless of status.
5 foreach ( glob( __DIR__ . '/includes/*.php' ) as $filename ) {
6 include_once $filename;
7 }
8
9 // Load the rest of the chatbot's functionality only when it's enabled.
10 if ( ! empty( $acb_settings['status'] ) && '1' === $acb_settings['status'] ) {
11
12 // Load controller.
13 foreach ( glob( __DIR__ . '/controller/*.php' ) as $filename ) {
14 include_once $filename;
15 }
16
17 // Load tools.
18 foreach ( glob( __DIR__ . '/tools/*.php' ) as $filename ) {
19 include_once $filename;
20 }
21
22 // Load models.
23 foreach ( glob( __DIR__ . '/models/*.php' ) as $filename ) {
24 include_once $filename;
25 }
26
27 // Load providers.
28 require_once __DIR__ . '/providers/class-wpsc-aibot-provider-interface.php';
29 foreach ( glob( __DIR__ . '/providers/*.php' ) as $filename ) {
30 if ( $filename === __DIR__ . '/providers/class-wpsc-aibot-provider-interface.php' ) {
31 continue;
32 }
33 include_once $filename;
34 }
35
36 // Load ui templates.
37 foreach ( glob( __DIR__ . '/templates/*.php' ) as $filename ) {
38 include_once $filename;
39 }
40 }
41