first_name) && empty($user->last_name)) ? $user_name = $user->display_name : $user_name = $user->first_name.' '.$user->last_name; $user_email = $user->user_email; if (!empty($_POST['info'])) { wphc_info_page_token_set(); $url = __('System Profile:', 'wphelpcenter')."\n\n ".wphc_info_page_url(); } else { $url = ''; } if ($_POST['calltime'] == 'ASAP') { $calltime = __('ASAP', 'wphelpcenter'); } else { $calltime = stripslashes($_POST['calltime_at']); } $body = ' '.__('WordPress HelpCenter Call Request', 'wphelpcenter').' ============================================ '.__('From: ', 'wphelpcenter').$user_name.' '.__('Email: ', 'wphelpcenter').$user_email.' '.__('Phone: ', 'wphelpcenter').stripslashes($_POST['phone']).' '.__('Call at: ', 'wphelpcenter').$calltime.' '.sprintf(__('(detected time zone: %s)', 'wphelpcenter'), stripslashes($_POST['timezone'])).' '.__('Browser: ', 'wphelpcenter').$_SERVER['HTTP_USER_AGENT'].' '.$url.' ============================================ '; wp_mail(WPHC_EMAIL, __('Call Request from ', 'wphelpcenter').$user_name, $body, 'From: "'.$user_name.'" <'.$user_email.'>'); ?>

Thank you for your request to WordPress HelpCenter. We will call as close to your requested time as possible.', 'wphelpcenter'); ?>

first_name) && empty($user->last_name)) ? $user_name = $user->display_name : $user_name = $user->first_name.' '.$user->last_name; $user_email = $user->user_email; wphc_info_page_token_set(); $body = ' '.__('WordPress HelpCenter System Profile', 'wphelpcenter').' ============================================ '.__('From: ', 'wphelpcenter').$user_name.' '.__('Email: ', 'wphelpcenter').$user_email.' '.__('Browser: ', 'wphelpcenter').$_SERVER['HTTP_USER_AGENT'].' '.__('System Profile:', 'wphelpcenter')."\n\n ".wphc_info_page_url().' ============================================ '; wp_mail(WPHC_EMAIL, __('System Profile from ', 'wphelpcenter').$user_name, $body, 'From: "'.$user_name.'" <'.$user_email.'>'); ?>

Thank you. Information about your WordPress installation has been sent to WordPress HelpCenter.
Keep this plugin active to make your System Profile available.', 'wphelpcenter'); ?>

wphc = {} wphc.timezone = function() { var timezone = (new Date().getTimezoneOffset()/60)*(-1); return timezone; } wphc.loading = function() { return '
'; } jQuery(function($) { $('body').append(''); $('#wphc_tab a.tab').click(function() { $('#wphc_tab div.content').slideToggle('fast', function() { if ($.browser.msie && $.browser.version == 6) { if ($(this).is(':visible')) { $('select').css('visibility', 'hidden'); } else { $('select').css('visibility', 'visible'); } } }); return false; }); $('#wphc_tab .inner .footer a, #wphc_tab a.newwin').click(function() { window.open($(this).attr('href')); return false; }); $('#wphc_tab #wphc_call_form_toggle, #wphc_phone_cancel').unbind().click(function() { $('#wphc_tab #wphc_call_form').slideToggle('fast', function() { $('#wphc_tab #wphc_phone:visible').focus(); }); return false; }); $('#wphc_tab #wphc_info_form_toggle, #wphc_info_cancel').unbind().click(function() { $('#wphc_tab #wphc_info_form').slideToggle('fast'); return false; }); $('#wphc_calltime_at_time').click(function() { $('#wphc_calltime_at').attr('checked', true); }); $('#wphc_call_form').submit(function() { var form = $(this); var phone = $('#wphc_phone'); if (phone.val() == '') { alert('Please enter your phone number.'); phone.css('background', '#ffc').focus(); return false; } $(this).hide(); var target = $('#wphc_call_form_response'); target.html(wphc.loading()).show(); $.post( '/index.php', { cf_action: 'wphc_request_call', phone: phone.val(), calltime: $(this).find('input[name=wphc_calltime]:checked').val(), calltime_at: $('#wphc_calltime_at_time').val(), timezone: wphc.timezone(), info: $('#wphc_call_info').val() }, function(response) { target.html(response); $('#wphc_call_form_response a.button').click(function() { target.slideUp(); return false; }); } ); return false; }); $('#wphc_info_form').submit(function() { var form = $(this); $(this).hide(); var target = $('#wphc_info_form_response'); target.html(wphc.loading()).show(); $.post( '/index.php', { cf_action: 'wphc_send_info', timezone: wphc.timezone() }, function(response) { target.html(response); $('#wphc_info_form_response a.button').click(function() { target.slideUp(); return false; }); } ); return false; }); if ($.browser.msie && $.browser.version == 6) { $('#wphc_tab div.inner').append('
 
'); } }); fieldset.options div.option { background: #EAF3FA; margin-bottom: 8px; padding: 10px; } fieldset.options div.option label { display: block; float: left; font-weight: bold; margin-right: 10px; width: 150px; } fieldset.options div.option span.help { color: #666; font-size: 11px; margin-left: 8px; } #wphc_tab { left: 50%; margin-left: -225px; position: absolute; overflow: hidden; text-align: center; top: 0; width: 450px; z-index: 999; } #wphc_tab div.content { background: #8c8c8c; border-radius-bottom-left: 6px; border-radius-bottom-right: 6px; -moz-border-radius-bottomleft: 6px; -moz-border-radius-bottomright: 6px; -webkit-border-radius-bottom-left: 6px; -webkit-border-radius-bottom-right: 6px; display: none; padding: 0 6px 6px; } #wphc_tab div.content div.inner { background: #fff; border-radius-bottom-left: 3px; border-radius-bottom-right: 3px; -moz-border-radius-bottomleft: 3px; -moz-border-radius-bottomright: 3px; -webkit-border-radius-bottom-left: 3px; -webkit-border-radius-bottom-right: 3px; text-align: left; } #wphc_tab div.content div.inner ul { margin-bottom: 10px; } #wphc_tab div.content div.inner p, #wphc_tab div.content div.inner li { margin: 0; padding: 0 10px 10px; } #wphc_tab #wphc_call_form_toggle, #wphc_tab #wphc_info_form_toggle { font-weight: bold; } #wphc_tab div.content div.inner li { padding: 0 10px 5px 15px; } #wphc_tab div.content div.inner p.intro { font-size: 14px; padding: 10px; text-align: center; } #wphc_tab div.content div.inner p.info { font-size: 11px; } #wphc_tab div.content div.inner div.contact { background: #8c8c8c; color: #fff; margin: 0 0 10px; } #wphc_tab div.content div.inner p.contact { font: 22px Georgia,"Times New Roman","Bitstream Charter",Times,serif; padding: 10px; text-align: center; } #wphc_tab div.content div.inner p.contact span { display: block; font-size: 16px; } #wphc_tab div.content div.inner p.contact span a, #wphc_tab div.content div.inner p.contact span a:visited { color: #fff; } #wphc_tab div.content div.inner div.contact p.reference-code { font-size: 11px; text-align: center; } #wphc_tab div.content div.inner div.contact p.reference-code b { background: #797979; font: bold 14px "Courier New", monospace; padding: 3px 5px; } #wphc_tab div.content div.inner form { display: none; zoom: 1; } #wphc_tab div.content div.inner form input.text { font-size: 12px; padding: 1px; } #wphc_tab div.content div.inner .response { background: #dfdfdf; margin: 0 10px 10px; padding: 10px; text-align: center; } #wphc_tab div.content div.inner .response p { font-size: 14px; } #wphc_tab div.content div.inner .response p span.small { display: block; font-size: 11px; margin-top: 5px; } #wphc_tab div.content .loading { background: url(//wphelpcenter/img/spinner.gif) 10px 13px no-repeat; clear: both; color: #ccc; height: 50px; margin-left: 10px; } #wphc_tab div.content .loading span { display: block; padding: 13px 32px 0; } #wphc_tab div.content div.inner p.footer { background: #dfdfdf; border-radius-bottom-left: 3px; border-radius-bottom-right: 3px; -moz-border-radius-bottomleft: 3px; -moz-border-radius-bottomright: 3px; -webkit-border-radius-bottom-left: 3px; -webkit-border-radius-bottom-right: 3px; font-size: 11px; margin: 0; padding: 8px; text-align: center; } #wphc_tab .ie6shim { background: #dfdfdf; } #wphc_tab a.tab { =')) { $tab_img = get_bloginfo('wpurl').'/'.PLUGINDIR.'/wphelpcenter/img/tab-gray-3.0.png'; } else { $tab_img = get_bloginfo('wpurl').'/'.PLUGINDIR.'/wphelpcenter/img/tab-gray.png'; } ?> background: url() no-repeat top center; display: block; height: 40px; margin: 0 auto; overflow: hidden; text-indent: -2000px; width: 230px; } #wphc-icon-32 { background: url(//wphelpcenter/img/wphc-lifering-32.png) no-repeat; } =')) { $tab_img = get_bloginfo('wpurl').'/'.PLUGINDIR.'/wphelpcenter/img/tab-blue-2.8.png'; $bgcolor = '#336da0'; $code_bgcolor = '#1d507d'; } else { $tab_img = get_bloginfo('wpurl').'/'.PLUGINDIR.'/wphelpcenter/img/tab-blue.png'; $bgcolor = '#195277'; $code_bgcolor = '#195277'; } ?> #wphc_tab div.content, #wphc_tab div.content div.inner div.contact, #wphc_tab .ie6shim { background: ; } #wphc_tab div.content div.inner div.contact p.reference-code b { background: ; } #wphc_tab a.tab { background-image: url(); } #wphc_tab div.content div.inner .response, #wphc_tab div.content div.inner p.footer { background: #eaf3fa; } =')) { ?> #wphc_tab div.content { background: #f8f8f7; } #wphc_tab div.content div.inner div.contact, #wphc_tab div.content div.inner p.contact span a, #wphc_tab div.content div.inner p.contact span a:visited { background: #dfdfdf; color: #464646; } =') ? $ie_img = get_bloginfo('wpurl').'/'.PLUGINDIR.'/wphelpcenter/img/tab-blue-2.8.gif' : $ie_img = get_bloginfo('wpurl').'/'.PLUGINDIR.'/wphelpcenter/img/tab-blue.gif'; break; default: version_compare($wp_version, '3.0', '>=') ? $ie_img = get_bloginfo('wpurl').'/'.PLUGINDIR.'/wphelpcenter/img/tab-gray-3.0.gif' : $ie_img = get_bloginfo('wpurl').'/'.PLUGINDIR.'/wphelpcenter/img/tab-gray.gif'; break; } echo ' '; } add_action('admin_head', 'wphc_admin_head'); function wphc_color_scheme() { $user = wp_get_current_user(); return get_usermeta($user->ID, 'admin_color'); } function wphc_tab() { $sys_profile = get_bloginfo('wpurl').'/wp-admin/index.php?page='.basename(__FILE__); $output = '

'.__('Your on-call resource for all things WordPress.', 'wphelpcenter').'

'.__('Call Us Now:', 'wphelpcenter').' '.WPHC_PHONE.''.__('or email:', 'wphelpcenter').' '.WPHC_EMAIL.'

'; if (wphc_reference_id() != '') { $output .= '

'.sprintf(__('Please provide code: %s', 'wphelpcenter'), wphc_reference_id()).'

'; } $output .= '

'.__('We can help with everything from development to troubleshooting. plugins to themes, installation to configuration.', 'wphelpcenter').'

'.__("I'd like someone to call me", 'wphelpcenter').'

or Cancel

'.__('Send System Profile to WordPress HelpCenter', 'wphelpcenter').'

'.sprintf(__('This will send your System Profile details to WordPress HelpCenter. This information may be useful for troubleshooting, answering questions, etc.', 'wphelpcenter'), $sys_profile).'

or '.__('Cancel', 'wphelpcenter').'

WordPress HelpCenter
'; $output = str_replace(array("\t", "\n"), '', $output); return $output; } function wphc_info_page_token_set() { $token = md5(microtime().get_bloginfo('url')).'_'.date('Ymd', strtotime('+3 days')); if (get_option('wphc_info_page_token') == '') { add_option('wphc_info_page_token', $token); } else { update_option('wphc_info_page_token', $token); } } function wphc_info_page_token_get() { $token = get_option('wphc_info_page_token'); if (empty($token)) { return false; } $token = explode('_', $token); return $token[0]; } function wphc_info_page_token_check($token = 'example') { // check date $key = get_option('wphc_info_page_token'); $date = explode('_', $key); $date = $date[1]; if (intval($date) < intval(date('Ymd'))) { return false; } // check token return (wphc_info_page_token_get() == $token); } function wphc_info_page_url() { return get_bloginfo('url').'/index.php?cf_action=wphc_system_profile&token='.wphc_info_page_token_get(); } function wphc_info_page() { wp_enqueue_script('jquery'); get_header(); wphc_info_page_content(); get_footer(); } function wphc_info_page_content() { include_once(ABSPATH.'/wp-admin/includes/plugin.php'); include_once(ABSPATH.'/wp-admin/includes/theme.php'); global $wp_version; version_compare('2.7', $wp_version, '<=') ? $icon = '

' : $icon = ''; print('
'.$icon.'

'.__('WordPress HelpCenter System Profile', 'wphelpcenter').'

'.__('Server Environment', 'wphelpcenter').'

'.__('PHP Version', 'wphelpcenter').' '.phpversion().'
'.__('PHP Extensions', 'wphelpcenter').' '.implode(', ', get_loaded_extensions()).'
'.__('MySQL Version', 'wphelpcenter').' '.mysql_get_server_info().'
'.__('Web Server', 'wphelpcenter').' '.$_SERVER['SERVER_SOFTWARE'].'
'); global $wpmu_version, $wp_version; is_null($wpmu_version) ? $wp_type = __('WordPress (single user)', 'wphelpcenter') : $wp_type = __('WordPress MU', 'wphelpcenter'); // adapted from wp-admin/plugins.php, WP 2.7 $all_plugins = get_plugins(); $active_plugins = array(); $inactive_plugins = array(); foreach ( (array)$all_plugins as $plugin_file => $plugin_data) { //Filter into individual sections if ( is_plugin_active($plugin_file) ) { $active_plugins[ $plugin_file ] = $plugin_data; } else { $inactive_plugins[ $plugin_file ] = $plugin_data; } } // adapted from wp-admin/themes.php, WP 2.7 $themes = get_themes(); $ct = current_theme_info(); $sidebar_widgets = ''; $current_sidebar = ''; $active_widgets = get_option('sidebars_widgets'); if (is_array($active_widgets) && count($active_widgets)) { foreach ($active_widgets as $sidebar => $widgets) { if (is_array($widgets)) { if ($sidebar != $current_sidebar) { $sidebar_widgets .= ''.$sidebar.': '; $current_sidebar = $sidebar; } if (count($widgets)) { $sidebar_widgets .= implode(', ', $widgets); } else { $sidebar_widgets .= __('(none)', 'wphelpcenter'); } $sidebar_widgets .= '
'; } } } get_option('permalink_structure') == '' ? $permalinks = __('Query String (index.php?p=123)', 'wphelpcenter') : $permalinks = __('Pretty Permalinks', 'wphelpcenter'); get_option('users_can_register') == '1' ? $reg = __('Yes', 'wphelpcenter') : $reg = __('No', 'wphelpcenter'); get_option('enable_xmlrpc') == '1' ? $xmprpc = __('Yes', 'wphelpcenter') : $xmprpc = __('No', 'wphelpcenter'); get_option('enable_app') == '1' ? $atompub = __('Yes', 'wphelpcenter') : $atompub = __('No', 'wphelpcenter'); get_option('blog_public') == '1' ? $privacy = __('Public', 'wphelpcenter') : $privacy = __('Private', 'wphelpcenter'); get_option('rss_use_excerpt') == '1' ? $feed = __('Summaries', 'wphelpcenter') : $feed = __('Full Content', 'wphelpcenter'); print('

'.__('WordPress Environment', 'wphelpcenter').'

'.__('Type', 'wphelpcenter').' '.$wp_type.'
'.__('Version', 'wphelpcenter').' '.$wp_version.'
'.__('File Path', 'wphelpcenter').' '.ABSPATH.'
'.__('Site URL', 'wphelpcenter').' '.get_bloginfo('url').'
'.__('WordPress URL', 'wphelpcenter').' '.get_bloginfo('wpurl').'
'.__('Permalink Type', 'wphelpcenter').' '.$permalinks.'
'.__('Registration Enabled', 'wphelpcenter').' '.$reg.'
'.__('XML-RPC Enabled', 'wphelpcenter').' '.$xmprpc.'
'.__('Atom Pub Enabled', 'wphelpcenter').' '.$atompub.'
'.__('Privacy Settings', 'wphelpcenter').' '.$privacy.'
'.__('Feed Content', 'wphelpcenter').' '.$feed.'
'.__('Active Plugins', 'wphelpcenter').'
    '); foreach ( (array)$active_plugins as $plugin_file => $plugin_data) { print('
  • '.wp_specialchars($plugin_data['Title']).' — '.__('version:', 'wphelpcenter').' '.wp_specialchars($plugin_data['Version']).'
  • '); } print('
'.__('Inactive Plugins', 'wphelpcenter').'
    '); foreach ( (array)$inactive_plugins as $plugin_file => $plugin_data) { print('
  • '.wp_specialchars($plugin_data['Title']).' — '.__('version:', 'wphelpcenter').' '.wp_specialchars($plugin_data['Version']).'
  • '); } print('
'.__('Current Theme', 'wphelpcenter').' '.sprintf(_c('%1$s %2$s by %3$s|1: theme title, 2: theme version, 3: theme author'), $ct->title, $ct->version, $ct->author).'
'.__('Sidebars / Widgets', 'wphelpcenter').' '.$sidebar_widgets.'
'); do_action('wphc_info_page_content'); } function wphc_denied_page() { wp_die(__('Sorry, your System Profile token has expired or is invalid. Please request a new one.', 'wphelpcenter')); } function wphc_admin_menu() { if (current_user_can('manage_options')) { add_submenu_page( 'index.php', __('System Profile', 'wphelpcenter'), __('System Profile', 'wphelpcenter'), 10, basename(__FILE__), 'wphc_info_page_content' ); } } add_action('admin_menu', 'wphc_admin_menu'); //a:21:{s:11:"plugin_name";s:20:"WordPress HelpCenter";s:10:"plugin_uri";s:23:"http://wphelpcenter.com";s:18:"plugin_description";s:76:"Easily contact WordPress HelpCenter for questions, etc. regarding WordPress.";s:14:"plugin_version";s:3:"1.0";s:6:"prefix";s:4:"wphc";s:12:"localization";s:12:"wphelpcenter";s:14:"settings_title";s:20:"WordPress HelpCenter";s:13:"settings_link";s:20:"WordPress HelpCenter";s:4:"init";b:0;s:7:"install";b:0;s:9:"post_edit";b:0;s:12:"comment_edit";b:0;s:6:"jquery";s:1:"1";s:6:"wp_css";b:0;s:5:"wp_js";b:0;s:9:"admin_css";s:1:"1";s:8:"admin_js";s:1:"1";s:15:"request_handler";s:1:"1";s:6:"snoopy";b:0;s:11:"setting_cat";b:0;s:14:"setting_author";b:0;} endif; // loaded check ?>