$marr) { $tp = get_post($marr); if($tp === null) { unset($myop[$mind]); $changedone = true; } } if($changedone == true) { aimogen_update_option('aimogen_chat_page_id', $myop); } if (!isset($value['remote_chat']) || trim($value['remote_chat']) != 'on') { foreach($myop as $mind => $marr) { wp_delete_post($marr, true); delete_option('aimogen_chat_page_id'); } } } } else { if(!isset($value['remote_chat'])) { $myop = get_option('aimogen_chat_page_id', false); if($myop !== false) { if(is_numeric($myop)) { $myop = array($myop); } foreach($myop as $mind => $marr) { wp_delete_post($marr, true); delete_option('aimogen_chat_page_id'); } } } } } add_action('aimogen_update_option_aimogen_Chatbot_Settings', 'aimogen_chat_settings_updated', 10, 3); function aimogen_chatbot_panel() { $aimogen_Main_Settings = get_option('aimogen_Main_Settings', false); if (!isset($aimogen_Main_Settings['app_id']) || trim($aimogen_Main_Settings['app_id']) == '') { ?>

Privacy Policy. Your data will only be used to assist with your inquiry."; } if (isset($aimogen_Chatbot_Settings['gdpr_checkbox'])) { $gdpr_checkbox = $aimogen_Chatbot_Settings['gdpr_checkbox']; } else { $gdpr_checkbox = "I agree to the terms."; } if (isset($aimogen_Chatbot_Settings['gdpr_button'])) { $gdpr_button = $aimogen_Chatbot_Settings['gdpr_button']; } else { $gdpr_button = "Start chatting"; } if (isset($aimogen_Chatbot_Settings['god_preview'])) { $god_preview = $aimogen_Chatbot_Settings['god_preview']; } else { $god_preview = ''; } if (isset($aimogen_Chatbot_Settings['enable_front_end'])) { $enable_front_end = $aimogen_Chatbot_Settings['enable_front_end']; } else { $enable_front_end = ''; } if (isset($aimogen_Chatbot_Settings['window_location'])) { $window_location = $aimogen_Chatbot_Settings['window_location']; } else { $window_location = ''; } if (isset($aimogen_Chatbot_Settings['window_width'])) { $window_width = $aimogen_Chatbot_Settings['window_width']; } else { $window_width = ''; } if (isset($aimogen_Chatbot_Settings['chatbot_icon_html'])) { $chatbot_icon_html = $aimogen_Chatbot_Settings['chatbot_icon_html']; } else { $chatbot_icon_html = ''; } if($assistant_id != '') { $assistant_found = false; if(is_array($all_assistants)) { foreach($all_assistants as $myassistant) { if ($assistant_id == $myassistant->ID) { $assistant_found = true; } } } if($assistant_found === false) { $assistant_id = ''; } } ?>

 

'; } ?> 'aimogen_personas', 'posts_per_page' => 12, 'paged' => $aimogen_persona_page, 'order' => 'DESC', 'orderby' => 'date', 'post_status' => 'any' )); if ($assistant_id != '') { echo ''; } else { ?>

' . esc_html__("An AI Assistant is selected for the chatbot. In this case, the below settings are loaded directly from the Assistant configuration. You can manage these settings in the AI Assistant settings.", 'aimogen') . '

'; echo wp_kses_post($image);?> id="aimogen_image_id" value="" class="regular-text" /> type='button' class="hideAssistantIDMain button-primary" value="" id="aimogen_media_manager"/> type='button' class="hideAssistantIDMain button-primary" value="" id="aimogen_media_clear"/>


' . esc_html__("Chatbot personas are not available when AI Assistants are used, as in this case, the persona configuration is loaded from the AI Assistant configuration. To use AI Personas, disable AI Assistants in the 'Bot Assistant Name' settings field.", 'aimogen') . '
have_posts()) { echo '   ' . esc_html__("No chatbot personas added. Add them in the 'Manage Chatbot Personas' tab.", 'aimogen'); } else { foreach ($aimogen_personas->posts as $aimogen_persona) { echo '
'; $att_src = get_the_post_thumbnail_url( $aimogen_persona->ID, 'thumbnail' ); if ( $att_src ) { echo '
User Avatar
'; } else { echo '
' . esc_html__("No avatar added", 'aimogen') . '
'; } echo '
' . esc_html($aimogen_persona->post_title) . '

' . esc_html($aimogen_persona->post_excerpt) . '

'; echo '
'; } } ?>
have_posts() && $aimogen_personas->max_num_pages > 1) { ?>
admin_url('admin.php?page=aimogen_chatbot_panel&wpage=%#%'), 'total' => $aimogen_personas->max_num_pages, 'current' => $aimogen_persona_page, 'format' => '?wpage=%#%', 'show_all' => false, 'prev_next' => true, 'add_args' => false, ))); ?>

>
>
>
>
>
>
>
>
>
>
>

'; echo wp_kses_post($image); ?>
>

>


have_posts()){ echo '

' . esc_html__('All personas', 'aimogen') . ' (' . esc_html($aimogen_personas->found_posts) . ')
'; } ?> have_posts()) { foreach ($aimogen_personas->posts as $aimogen_persona) { ?> '; } ?>
post_title);?> post_excerpt);?> ID, 'thumbnail'); if($avatar === false){echo 'N/A';}else{echo 'avatar';}?> ID);?> post_date)?>
' . esc_html__("No chatbot personas added. You can add more using the 'Add New Persona' button from above.", 'aimogen') . '
have_posts() && $aimogen_personas->max_num_pages > 1) { ?>
admin_url('admin.php?page=aimogen_chatbot_panel&wpage=%#%'), 'total' => $aimogen_personas->max_num_pages, 'current' => $aimogen_persona_page, 'format' => '?wpage=%#%', 'show_all' => false, 'prev_next' => true, 'add_args' => false, ))); ?>


'aimogen_Chatbot_Settings[custom_header]', 'media_buttons' => true, 'quicktags' => true, 'tabindex' => '4', 'editor_height' => 80, 'teeny' => false ); wp_editor( $custom_header, 'custom_header', $settings ); ?>
'aimogen_Chatbot_Settings[custom_footer]', 'media_buttons' => true, 'quicktags' => true, 'tabindex' => '4', 'editor_height' => 80, 'teeny' => false ); wp_editor( $custom_footer, 'custom_footer', $settings ); ?>
'aimogen_Chatbot_Settings[custom_css]', 'media_buttons' => true, 'quicktags' => true, 'tabindex' => '4', 'editor_height' => 80, 'teeny' => false ); wp_editor( $custom_css, 'custom_css', $settings ); ?>


have_posts()) { echo ''; } else { echo ''; } ?>

' . esc_html__("Note: GPT-5-Pro models do not support response streaming. Please select another option.", 'aimogen') . ''; } ?>
>

>
Privacy Policy. Your data will only be used to assist with your inquiry.", 'aimogen'); ?>

"/>

×


:


:


:


:


:


:





×



:


:





:




'yes', 'temperature' => '', 'top_p' => '', 'presence_penalty' => '', 'frequency_penalty' => '', 'model' => '', 'instant_response' => '', 'show_in_window' => 'off' ); if($god_preview == 'on') { $preview_settings['enable_god_mode'] = 'yes'; } // ignore, as it is a safe shortcode // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped echo aimogen_chat_shortcode($preview_settings); ?>



$value) { $uniqum = $value->index; $data = $value->data; $uniq = uniqid(); if(empty($data->rule_description)) { $data->rule_description = $uniqum; } $output .= '
×

' . esc_html__("Rule ID ", 'aimogen') . esc_html(stripslashes($dataid)) . ' ' . esc_html__("Advanced Settings", 'aimogen') . '

' . esc_html__("Set a list of URL where to not show the chatbot. You can enter multiple URLs, each on a new line.", 'aimogen') . '
' . esc_html__("Do Not Show The Chatbot On These URLs:", 'aimogen') . '
' . esc_html__("Set a list of URL only where to show the chatbot. You can enter multiple URLs, each on a new line. If you enter a list of URLs, the chatbot will be shown only on these URls and not on any other URLs from your site.", 'aimogen') . '
' . esc_html__("Show The Chatbot Only On These URLs:", 'aimogen') . '
' . esc_html__("Set the hour period of each day, when you want to show the chatbot embedded on your site. Your current server time is: ", 'aimogen') . gmdate("h:i A") . '
' . esc_html__("Show The Chatbot Between Specific Hours Each Day:", 'aimogen') . '
-
' . esc_html__("Set the days of the week, when you want to always show the chatbot (regardless of the above hour limitations).", 'aimogen') . '
' . esc_html__("Days When To Always Show The Chatbot:", 'aimogen') . '
' . esc_html__("Set the days of the week, when you want to never show the chatbot.", 'aimogen') . '
' . esc_html__("Days When To Never Show The Chatbot:", 'aimogen') . '
' . esc_html__("Select the WordPress content where to not show the chatbot.", 'aimogen') . '
' . esc_html__("Do Not Show The Chatbot On This WordPress Content:", 'aimogen') . '
' . esc_html__("Select the WordPress content only where to show the chatbot.", 'aimogen') . '
' . esc_html__("Show The Chatbot Only On This WordPress Content:", 'aimogen') . '
' . esc_html__("Select the languages for which the chatbot will not be shown.", 'aimogen') . '
' . esc_html__("Do Not Show The Chatbot For These Languages:", 'aimogen') . '
' . esc_html__("Select the languages for only which the chatbot will be shown.", 'aimogen') . '
' . esc_html__("Show The Chatbot Only For These Languages:", 'aimogen') . '
' . esc_html__("Select the user roles for which the chatbot will not be shown.", 'aimogen') . '
' . esc_html__("Do Not Show The Chatbot For These User Roles:", 'aimogen') . '
' . esc_html__("Select the user roles for only which the chatbot will be shown.", 'aimogen') . '
' . esc_html__("Show The Chatbot Only For These User Roles:", 'aimogen') . '
' . esc_html__("Select the devices for which the chatbot will not be shown.", 'aimogen') . '
' . esc_html__("Do Not Show The Chatbot For These Devices:", 'aimogen') . '
' . esc_html__("Select the devices for only which the chatbot will be shown.", 'aimogen') . '
' . esc_html__("Show The Chatbot Only For These Devices:", 'aimogen') . '
' . esc_html__("Select the Operating Systems for which the chatbot will not be shown.", 'aimogen') . '
' . esc_html__("Do Not Show The Chatbot For These Operating Systems:", 'aimogen') . '
' . esc_html__("Select the Operating Systems for only which the chatbot will be shown.", 'aimogen') . '
' . esc_html__("Show The Chatbot Only For These Operating Systems:", 'aimogen') . '
' . esc_html__("Select the Browsers for which the chatbot will not be shown.", 'aimogen') . '
' . esc_html__("Do Not Show The Chatbot For These Browsers:", 'aimogen') . '
' . esc_html__("Select the Browsers for only which the chatbot will be shown.", 'aimogen') . '
' . esc_html__("Show The Chatbot Only For These Browsers:", 'aimogen') . '
' . esc_html__("Select the IP Addresses for which the chatbot will not be shown. List of IP addresses or IP ranges. Examples: 46.33.233.31, 46.0-46.1", 'aimogen') . '
' . esc_html__("Do Not Show The Chatbot For These IP Addresses:", 'aimogen') . '
' . esc_html__("Select the IP Addresses for only which the chatbot will be shown. List of IP addresses or IP ranges. Examples: 46.33.233.31, 46.0-46.1", 'aimogen') . '
' . esc_html__("Show The Chatbot Only For These IP Addresses:", 'aimogen') . '
X
'; $cont++; } } return $output; } ?>