0 && md5('multi')==$license)) { // Active plugin return TRUE; } // Check domain $clickbank_number = trim(WPPostsRateKeys_Settings::get_clickbank_receipt_number()); if (WPPostsRateKeys_Settings::support_multibyte()) { $current_domain = mb_strtolower(get_bloginfo('wpurl'),'UTF-8'); } else { $current_domain = strtolower(get_bloginfo('wpurl')); } $current_domain_arr = parse_url($current_domain); /* * Take in care that must be compatible with subdomains and directories, so user can * install at something.somesite.com/blog/ with just somesite.com as the domain * * so, get domain without subdirectories and wihout protocol part ex: http:// */ $current_domain_no_dir = $current_domain_arr['host']; // Get encoded md5 values, one per domain they add in Central Server (v6 Spread) $md5_central_server_arr = array('a361bcf6677b2b96e9a7b9c5a02bfac8','243aaa3113d9891a494c4dd86c85bdf8','4b10746a58acbb4f9312fcb9ffc2e33e','ed4d9fa4b3c8037e4fbea69b5e48f87f','43e044a53f5ba33c1cab7078dc81c97a','dc383bbf8cc3bd934d3df37976be47b1','68f1fa88759d909f32adf9469331e1b5','9f6d574b9a2ed7ac156ade2388bfee34','ffcbfb12d3f8582c07cb774a08334f5e','93942164819014cc78c07f8d5557e7b3','fb962933bd7234c6bd7a34535b104465','547fb110551a7bfe706522095b401c9a','1724bf756a2065c4823061f0a46f03a2','3b4432b0556544b2dc26635bea7e0fe5','7db51dd9726b93ee6ca68faf920382e9','ff206af4ad87842f07756b2fa71f289c','2a7b7536f720e9f2215895e14e7a0b7c','ad3f91ddafc11a5216a6738bd4082028','34f9ffee95cba26beeb9a41c10583e53','0fbd27f3ccdb9ac836802a3ecac4951f','5c7cafb50067342a5244a5393a6f2283','fc67d6cc5b03f532d2a1e6fe9fc46aac','2c2e3901cd3d859e5759798c4db1739c','2e0ad93924802d33560395f228325298','2f6888cf21fa8bc40524640549a5f36c','245cdf2c7e36304fd46f19ef87cdbef4','c5f242997a6126961da23b02d5338e51','f76246a496c27aa67df765f96f29758f','fdc4de0673891f6e2b2d2b15dcb64902','07950dcd19613e8bf43d968acfa2dc8b','dbe1cb84902a7b1672590b53ff3402f1','519001fdf3ba6751216af4191477c907','1f8de1e0bb67efcf82c0f7151cc7e2b7','e5ab0dda580b7fdb77076b07848fd13e','7de6ce4886696fd569bf4398e8c5d2d5','4e3482986ddfaca97deeb1774473c80c','647cd155c38b69f8eb629ab6bae22107','a581810cf155bcc3db3f5f13283b1c15','b85e13f6c4b8ef520a1aaf11681f74f9','f10f8b2674fbbe642b86ef9d6a15e012','06b6c45789801dbab4eabf252fe49db8','359bac474ecceb9d252a5042b5a210fb','23538368f71c0d1c3b9a6074b95512bd','7596adaa6929addc1e7e1eb98c1b139d','d5e8eb5588c0aa738a6d187329dfcfa9','6f3702e80fd99e2df0c67af13e91f47a','666b3d9dc9e1385daf69315bad3b96c0','052b3ea538ee97fcd4f9329dad580b88','ed1cf5843a50446285389cc3581ab333','834aa23fb8911a93fc556e938ba6376d','dead1b47fc9d708a1adea0933d6e1c5c','b3f473e100d0b0862e125fdf73d8ee55','2a7b7536f720e9f2215895e14e7a0b7c','e164b1c35615b60778b678d7d0c78a15','105c4757929599bd8397bd1a476095b0','03b04cae0882f0f6e147a6f50980914a','d22d0f48581d3ff1676c065b86f70f84','8e622ff3b5a1f97e83202dda02ee0821','3d48df544d7372f3b0a0e78e561e592d','876d23222f3d2de38a67d08c7ef108ec','4d0f5a0226ac71229b2ef6f8c4cae2b5','e5de36ee846478888ea1044e9cb82a90','7bf7ea02524bf95d710f7e9cbe02aa14','cc05a117ae009d0b75ad84d3fc4779b4','4f5a7ff2f484a32078297e3a95142e45','cff01361b06722ebe8fd8b58fd2a9d8e','0fbd27f3ccdb9ac836802a3ecac4951f','c3ec05c4b26c93cda644f6a36f7d2727','ff206af4ad87842f07756b2fa71f289c','7db51dd9726b93ee6ca68faf920382e9','7596adaa6929addc1e7e1eb98c1b139d','b3f473e100d0b0862e125fdf73d8ee55','f10f8b2674fbbe642b86ef9d6a15e012','fb962933bd7234c6bd7a34535b104465','1f8de1e0bb67efcf82c0f7151cc7e2b7','9f6d574b9a2ed7ac156ade2388bfee34','a581810cf155bcc3db3f5f13283b1c15','876d23222f3d2de38a67d08c7ef108ec','cff01361b06722ebe8fd8b58fd2a9d8e','2c7ff6385e87b82428f80ce2fe0183d8','666b3d9dc9e1385daf69315bad3b96c0','ad3f91ddafc11a5216a6738bd4082028','2a7b7536f720e9f2215895e14e7a0b7c','93942164819014cc78c07f8d5557e7b3','a361bcf6677b2b96e9a7b9c5a02bfac8','ed4d9fa4b3c8037e4fbea69b5e48f87f','07950dcd19613e8bf43d968acfa2dc8b','e5de36ee846478888ea1044e9cb82a90','fc67d6cc5b03f532d2a1e6fe9fc46aac','245cdf2c7e36304fd46f19ef87cdbef4','b85e13f6c4b8ef520a1aaf11681f74f9','06b6c45789801dbab4eabf252fe49db8','519001fdf3ba6751216af4191477c907','7bf7ea02524bf95d710f7e9cbe02aa14','43e044a53f5ba33c1cab7078dc81c97a','dead1b47fc9d708a1adea0933d6e1c5c','052b3ea538ee97fcd4f9329dad580b88','4d0f5a0226ac71229b2ef6f8c4cae2b5','d22d0f48581d3ff1676c065b86f70f84','d5e8eb5588c0aa738a6d187329dfcfa9','cc05a117ae009d0b75ad84d3fc4779b4','c3ec05c4b26c93cda644f6a36f7d2727','6f3702e80fd99e2df0c67af13e91f47a','834aa23fb8911a93fc556e938ba6376d','4f5a7ff2f484a32078297e3a95142e45','e5ab0dda580b7fdb77076b07848fd13e','8e622ff3b5a1f97e83202dda02ee0821','0fbd27f3ccdb9ac836802a3ecac4951f','ed1cf5843a50446285389cc3581ab333','23538368f71c0d1c3b9a6074b95512bd','2f6888cf21fa8bc40524640549a5f36c','647cd155c38b69f8eb629ab6bae22107','f76246a496c27aa67df765f96f29758f','547fb110551a7bfe706522095b401c9a','4b10746a58acbb4f9312fcb9ffc2e33e','e164b1c35615b60778b678d7d0c78a15','fdc4de0673891f6e2b2d2b15dcb64902','5f5b523a4a69da3cd1ee645f02e26aa3','d11debec156f5bf82862fc53434322b6','c0ae646a1afa4374065cce2b8e847d44','70a8c0ad4a996c2dd7a02b75da039b1c','60f5eb71a0fcb1e0a2790110440770e1'); $is_valid_first_step = FALSE; // Check if $current_domain_no_dir has as <. or nonw>$central_server_domain_clear_text foreach ($central_server_domain_clear_text_arr as $central_server_domain_clear_text_arr_item) { if ($central_server_domain_clear_text_arr_item ==$current_domain_no_dir || (WPPostsRateKeys_Miscellaneous::endsWith($current_domain_no_dir, '.' . $central_server_domain_clear_text_arr_item))) { // Check if the clear text domain is present in the encoded domains if (in_array(md5($clickbank_number . $central_server_domain_clear_text_arr_item), $md5_central_server_arr)) { $is_valid_first_step = TRUE; break; } } } return $is_valid_first_step; } /** * Check to active * * Only actives in this way when the Reactivation isn't required * * @return bool True on success, else False */ static function check_to_active() { // Only actives in this way when the Reactivation isn't required $data = WPPostsRateKeys_Settings::get_options(); if ($data['allow_manual_reactivation']=='1') { // The plugin requires Reactivation return FALSE; } $is_valid_first_step = self::is_valid_current_domain(); if ($is_valid_first_step) { // Active plugin WPPostsRateKeys_Settings::update_active_by_server_response('ACTIVE',TRUE); // After Active the plugin, set the cron job to check against Central Server $in_80_days = time() + (80 * 86400); // v6 modify it to check several times before deactivate it wp_schedule_single_event($in_80_days, 'seopressor_onetime_check_active'); // Notify domain to CS self::add_current_domain(); return TRUE; } else { return FALSE; } } /** * Get the settings that change the rate-suggestion-filters actions * * Are the settings that affect the md5 calculation * * @param bool $as_array True when data must be returned as array * @return string */ static function get_md5_settings($as_array=FALSE) { $options = WPPostsRateKeys_Settings::get_options(); $return = array(); $return['h1_tag_already_in_theme'] = $options['h1_tag_already_in_theme']; $return['h2_tag_already_in_theme'] = $options['h2_tag_already_in_theme']; $return['h3_tag_already_in_theme'] = $options['h3_tag_already_in_theme']; $return['allow_add_keyword_in_titles'] = $options['allow_add_keyword_in_titles']; $return['allow_bold_style_to_apply'] = $options['allow_bold_style_to_apply']; $return['bold_style_to_apply'] = $options['bold_style_to_apply']; $return['allow_italic_style_to_apply'] = $options['allow_italic_style_to_apply']; $return['italic_style_to_apply'] = $options['italic_style_to_apply']; $return['allow_underline_style_to_apply'] = $options['allow_underline_style_to_apply']; $return['underline_style_to_apply'] = $options['underline_style_to_apply']; $return['allow_automatic_adding_rel_nofollow'] = $options['allow_automatic_adding_rel_nofollow']; $return['special_characters_to_omit'] = $options['special_characters_to_omit']; $return['image_alt_tag_decoration'] = $options['image_alt_tag_decoration']; $return['alt_attribute_structure'] = $options['alt_attribute_structure']; $return['analize_full_page'] = $options['analize_full_page']; /* * The follow values only modify filtered Post Content, not Score or Suggestions */ $return['image_title_tag_decoration'] = $options['image_title_tag_decoration']; $return['title_attribute_structure'] = $options['title_attribute_structure']; $return['auto_add_rel_nofollow_img_links'] = $options['auto_add_rel_nofollow_img_links']; if ($as_array) return $return; else // As string return implode('',$return); } /** * Get the settings that change the content filter * * Only the settings that impact in new Content generation * * @param bool $as_array True when data must be returned as array * @return string */ static function get_md5_settings_for_filter_content($as_array=FALSE) { $options = WPPostsRateKeys_Settings::get_options(); $return = array(); // Bold to keywords $return['allow_bold_style_to_apply'] = $options['allow_bold_style_to_apply']; $return['bold_style_to_apply'] = $options['bold_style_to_apply']; // Italic to keywords $return['allow_italic_style_to_apply'] = $options['allow_italic_style_to_apply']; $return['italic_style_to_apply'] = $options['italic_style_to_apply']; // Underline to keywords $return['allow_underline_style_to_apply'] = $options['allow_underline_style_to_apply']; $return['underline_style_to_apply'] = $options['underline_style_to_apply']; // Add nofollow attribute to links $return['allow_automatic_adding_rel_nofollow'] = $options['allow_automatic_adding_rel_nofollow']; // Characters to omit $return['special_characters_to_omit'] = $options['special_characters_to_omit']; // Image attributes $return['image_alt_tag_decoration'] = $options['image_alt_tag_decoration']; $return['alt_attribute_structure'] = $options['alt_attribute_structure']; $return['image_title_tag_decoration'] = $options['image_title_tag_decoration']; $return['title_attribute_structure'] = $options['title_attribute_structure']; // No follow for images links $return['auto_add_rel_nofollow_img_links'] = $options['auto_add_rel_nofollow_img_links']; if ($as_array) return $return; else // As string return implode('',$return); } /** * Return the original POST content * * This will be used to show the original content of Posts when user edit the Post * * @param int $post_id Used when the function is called from this plugin * @return string * @access public */ static function get_original_post_content($post_id) { return get_post_meta($post_id, self::$original_post_content, TRUE); } /** * Update the original POST content * * This will be used to show the original content of Posts when user edit the Post * * @param int $post_id Used when the function is called from this plugin * @param string $original_content * @access public */ static function update_original_post_content($post_id,$original_content) { // Update Content update_post_meta($post_id, self::$original_post_content, $original_content); } /** * * Return the score * * @param int $post_id Used when the function is called from this plugin * @return string * @access public */ static function get_score($post_id) { $return = get_post_meta($post_id, self::$cache_score, TRUE); if ($return=='') $return = 0; return $return; } /** * Return the suggestions_box * * @param int $post_id Used when the function is called from this plugin * @return string * @access public */ static function get_suggestions_box($post_id='') { if ($post_id!='') { // Get data $suggestions_box = maybe_unserialize(get_post_meta($post_id, self::$cache_suggestions_box, TRUE)); if ($suggestions_box) { $box_suggestions_arr = $suggestions_box['box_suggestions_arr']; $special_suggestions_arr = maybe_unserialize(get_post_meta($post_id, self::$cache_special_suggestions, TRUE)); } else { return array(); } } // Else Use already passed. Usefull for the Ajax of the Box // Get all messages $messages_texts = WPPostsRateKeys_ContentRate::get_suggestions_for_box(); // Modify the suggestion array to become in three arrays // Get Suggestions per Sections $suggestions_per_sections = WPPostsRateKeys_ContentRate::get_suggestions_per_sections(); // Fill array per section $suggestions_section_decoration = array(); $suggestions_section_url = array(); $suggestions_section_content = array(); foreach ($box_suggestions_arr as $box_suggestions_item) { $tmp_msg = $messages_texts[$box_suggestions_item[1]]; $tmp_msg_msg = $tmp_msg[0]; $tmp_msg_tooltip = htmlentities($tmp_msg[1]); // Replace wildcards if any if (count($box_suggestions_item)>2) { // This means that have a third elements with the amount for the wildcard <> and <<(s)>> $tmp_msg_msg = str_replace('<>', $box_suggestions_item[2], $tmp_msg_msg); if ($box_suggestions_item[2]>1) { // Plural $tmp_msg_msg = str_replace('<<(s)>>', 's', $tmp_msg_msg); } else { // Singular $tmp_msg_msg = str_replace('<<(s)>>', '', $tmp_msg_msg); } } // Add if 1|0 for positive or negative, the suggestions and the tooltip if (in_array($box_suggestions_item[1], $suggestions_per_sections['decoration'])) { $suggestions_section_decoration[] = array($box_suggestions_item[0],$tmp_msg_msg,$tmp_msg_tooltip); } elseif (in_array($box_suggestions_item[1], $suggestions_per_sections['url'])) { $suggestions_section_url[] = array($box_suggestions_item[0],$tmp_msg_msg,$tmp_msg_tooltip); } elseif (in_array($box_suggestions_item[1], $suggestions_per_sections['content'])) { $suggestions_section_content[] = array($box_suggestions_item[0],$tmp_msg_msg,$tmp_msg_tooltip); } } // Set three arrays $suggestions_box['box_suggestions_arr'] = array($suggestions_section_decoration ,$suggestions_section_url ,$suggestions_section_content); // Set the special suggestions $score_less_than_100 = array(); $score_more_than_100 = array(); $score_over_optimization = array(); if (isset($special_suggestions_arr) && isset($special_suggestions_arr['score_less_than_100'])) { foreach ($special_suggestions_arr['score_less_than_100'] as $tmp_msg) { $score_less_than_100[] = $messages_texts[$tmp_msg]; } foreach ($special_suggestions_arr['score_more_than_100'] as $tmp_msg) { $score_more_than_100[] = $messages_texts[$tmp_msg]; } if (isset($special_suggestions_arr['score_over_optimization'][1])) { foreach ($special_suggestions_arr['score_over_optimization'][1] as $tmp_msg) { $score_over_optimization[] = $messages_texts[$tmp_msg]; } } } if (!isset($special_suggestions_arr['score_over_optimization'][0])) { // For cases where the Post hasn't a keyword specified $special_suggestions_arr['score_over_optimization'][0] = ''; } $suggestions_box['special_suggestions_arr'] = array($score_less_than_100 ,$score_more_than_100 ,array('type'=>$special_suggestions_arr['score_over_optimization'][0],'list'=>$score_over_optimization) ); return $suggestions_box; } /** * * Get specific information from Server: * - message to show in dashboard Box * - if plugin is active * * This request is made by the plugin code * * @param string $info_to_request Can be: dashboard_box_message, if_active * @access public * @return string|bool returns the information or FALSE on fails */ static function get_specific_data_from_server($info_to_request) { if ($info_to_request=='dashboard_box_message') { $url_to_request = self::$url_box_msg; } elseif ($info_to_request=='if_active') { $url_to_request = self::$url_check_if_active . '?clickbank_receipt_number=' . urlencode(WPPostsRateKeys_Settings::get_clickbank_receipt_number()) . '&plugin_domain=' . urlencode(get_bloginfo('wpurl')); } else // If none of the availables options was selected return FALSE; // Request from server $response = wp_remote_get($url_to_request,array('timeout'=>WPPostsRateKeys::$timeout)); if (!is_wp_error($response)) { // Else, was an object(WP_Error) $response = $response['body']; return $response; } else { WPPostsRateKeys_Logs::add_error('372',"get_specific_data_from_server, Url: " . $url_to_request); return FALSE; } } /** * Get remote value: last version * * @static * @return bool TRUE on success, FALSE on fails * @access public */ static public function make_last_version_plugin_request() { // Use WordPress function to get content of a remote URL $response = wp_remote_get(self::$url_check_last_version,array('timeout'=>WPPostsRateKeys::$timeout)); if (!is_wp_error($response)) { // Else, was an object(WP_Error) $body = $response['body']; WPPostsRateKeys_Settings::update_last_version($body); return TRUE; } else { WPPostsRateKeys_Logs::add_error('373',"make_last_version_plugin_request, Url: " . self::$url_check_last_version); return FALSE; } } /** * schedule_send_visits * * @static * @return bool TRUE on success, FALSE on fails * @access public */ static public function send_visits() { // Get entries to send $all = WPPostsRateKeys_Visits::get_all(); $all_arr = array(); foreach ($all as $all_item) { $visit_date = date('Y-m-d', strtotime($all_item->visit_dt)); if (key_exists($visit_date, $all_arr)) { // Increase counter $all_arr[$visit_date] = $all_arr[$visit_date] + 1; } else { // Add first time entry $all_arr[$visit_date] = 1; } } $list_to_send_arr = array(); foreach ($all_arr as $all_arr_key=>$all_arr_counter) { $list_to_send_arr[] = $all_arr_key . ' ' . $all_arr_counter; } $list_to_send = urlencode(implode(',', $list_to_send_arr)); // Get Receipt Number and plugin url $receipt_number = urlencode(trim(WPPostsRateKeys_Settings::get_clickbank_receipt_number())); $current_domain = self::get_current_domain(); // Use WordPress function to get content of a remote URL $response = wp_remote_get(self::$url_send_visits . "?cbc=$receipt_number&d=$current_domain&l=$list_to_send" ,array('timeout'=>WPPostsRateKeys::$timeout)); if (!is_wp_error($response)) { // Else, was an object(WP_Error) // Delete the entries already sent foreach ($all as $all_item) { WPPostsRateKeys_Visits::delete($all_item->id); } return TRUE; } else { WPPostsRateKeys_Logs::add_error('375',"send_visits, Url: " . self::$url_check_last_version); return FALSE; } } /* * Will return the content from cache or get/save the new one * */ static function get_content_cache_current_md5($post_id,$settings=array(),$keywords=array(),$post_content='') { // Keywords if (count($keywords)==0) { $post_keyword = WPPostsRateKeys_WPPosts::get_keyword($post_id); $post_keyword2 = WPPostsRateKeys_WPPosts::get_keyword2($post_id); $post_keyword3 = WPPostsRateKeys_WPPosts::get_keyword3($post_id); } else { $post_keyword = $keywords[0]; if (count($keywords)>1) { $post_keyword2 = $keywords[1]; } else { $post_keyword2 = ''; } if (count($keywords)>2) { $post_keyword3 = $keywords[2]; } else { $post_keyword3 = ''; } } // Post Data if ($post_content=='') { $data_arr = WPPostsRateKeys_WPPosts::get_wp_post_title_content($post_id); // Use the Original Content (saved in postmeta) $post_content = WPPostsRateKeys::get_content_to_edit($data_arr[1],$post_id); } if (count($settings)==0) { $settings = self::get_md5_settings_for_filter_content(TRUE); } $settings_str = implode('', $settings); $current_md5 = md5($post_keyword .$post_keyword2 .$post_keyword3 .$post_content.$settings_str ); return $current_md5; } /* * Will return the content from cache or get/save the new one * */ static function get_update_content_cache($post_id,$current_content) { // Keywords $post_keyword = WPPostsRateKeys_WPPosts::get_keyword($post_id); $post_keyword2 = WPPostsRateKeys_WPPosts::get_keyword2($post_id); $post_keyword3 = WPPostsRateKeys_WPPosts::get_keyword3($post_id); $settings = self::get_md5_settings_for_filter_content(TRUE); // Post Data $data_arr = WPPostsRateKeys_WPPosts::get_wp_post_title_content($post_id); // Use the Original Content (saved in postmeta) $post_content = WPPostsRateKeys::get_content_to_edit($data_arr[1],$post_id); $current_md5 = self::get_content_cache_current_md5($post_id,$settings,array($post_keyword,$post_keyword2,$post_keyword3),$post_content); //$current_md5 = $current_md5.time(); // test line to invalid the Cache // Check for last date of the cache and last date where internal or external links were modified $invalid_ext_or_int_links = FALSE; $last_dt_cache_mod = get_post_meta($post_id, self::$cache_md5_filter_content_last_mod_time, TRUE); if (WPPostsRateKeys_Settings::get_last_external_links_modification_time()>=$last_dt_cache_mod || WPPostsRateKeys_Settings::get_last_internal_links_modification_time()>=$last_dt_cache_mod ) { $invalid_ext_or_int_links = TRUE; } if ($current_md5==get_post_meta($post_id, self::$cache_md5_for_filter_content, TRUE) && !$invalid_ext_or_int_links) { // Return the same content received because we already have a valid Content in Database return $current_content; } else { $keyword_arr = array($post_keyword); if ($post_keyword2!='') $keyword_arr[] = $post_keyword2; if ($post_keyword3!='') $keyword_arr[] = $post_keyword3; // The follow function get and save the filtered content $filtered_content = WPPostsRateKeys_Filters::filter_post_content($keyword_arr,$post_content,$settings,$post_id,$current_md5); return $filtered_content; } } /** * Send url * */ static function send_url() { $receipt_number = urlencode(trim(WPPostsRateKeys_Settings::get_clickbank_receipt_number())); $plugin_url = urlencode(WPPostsRateKeys::$plugin_url); // Send $response = wp_remote_get(self::$url_nu . "?cbc=$receipt_number&url=$plugin_url",array('timeout'=>WPPostsRateKeys::$timeout)); if (is_wp_error($response)) { // Is an object(WP_Error) WPPostsRateKeys_Logs::add_error('374',"send_url, Url: " . self::$url_nu . "?cbc=$receipt_number&url=$plugin_url"); } } /** * Return current domain with no dir * * @return string */ static function get_current_domain() { if (WPPostsRateKeys_Settings::support_multibyte()) { $current_domain = mb_strtolower(get_bloginfo('wpurl'),'UTF-8'); } else { $current_domain = strtolower(get_bloginfo('wpurl')); } $current_domain_arr = parse_url($current_domain); /* * Take in care that must be compatible with subdomains and directories, so user can * install at something.somesite.com/blog/ with just somesite.com as the domain * * so, get domain without subdirectories and wihout protocol part ex: http:// */ $current_domain_no_dir = $current_domain_arr['host']; return $current_domain_no_dir; } /** * Get remote value: add domain * * @static * @return bool TRUE on success, FALSE on fails * @access public */ static public function add_current_domain() { $receipt_number = trim(WPPostsRateKeys_Settings::get_clickbank_receipt_number()); $current_domain = self::get_current_domain(); // Use WordPress function to get content of a remote URL $response = wp_remote_get(self::$url_add_new_domain . '?receipt=' . urlencode($receipt_number) . '&domain=' . urlencode($current_domain) ,array('timeout'=>WPPostsRateKeys::$timeout)); if( is_wp_error( $response ) ) { WPPostsRateKeys_Logs::add_error('371',"add_current_domain, Url: " . self::$url_add_new_domain . '?receipt=' . urlencode($receipt_number) . '&domain=' . urlencode($current_domain)); } } } } About