onWebChat Settings Page


If you don\'t have an account on onWebChat live chat service create one here

'. '

To install onWebChat on your Wordpress site please insert the Chat Id to the following field.

'. '

You will find Chat Id in settings-page of onWebChat admin, login here

'. '

[You can customize chat widget appearance from settings admin page]

'; } // print the text of section field function onwebchat_setting_field_text() { $options = get_option('onwebchat_plugin_option'); echo ""; } // validate data input function plugin_options_validate($input) { $newinput['text_string'] = trim($input['text_string']); if(!preg_match('/^[a-f0-9\\/]{35,50}$/i', $newinput['text_string'])) { $newinput['text_string'] = ''; } return $newinput; } // print chat widget code function onwebchat_add_script_at_footer() { $options = get_option('onwebchat_plugin_option'); $chatId = $options['text_string']; $widgetCode = ""; //check if user is logged if yes get username, email (all users registered have them) if ( is_user_logged_in() ) { global $current_user; get_currentuserinfo(); // get user name $onwebchat_user = $current_user->user_login; // get user email $onwebchat_email = $current_user->user_email; //add api info $widgetCode = $widgetCode.""; } echo $widgetCode; } ?>