$v){ $val[$k] = mysql_escape_string($v); } return $val; }else{ $link = mysqli_connect(DB_HOST,DB_USER,DB_PASSWORD,DB_NAME) or die(mysqli_connect_error() ); return mysqli_real_escape_string($link, $val); } } function run_query($query, $is_multiquery=false){ //$query; $link = mysqli_connect(DB_HOST,DB_USER,DB_PASSWORD,DB_NAME) or die(mysqli_connect_error() ); mysqli_set_charset($link ,'utf8' ); if($is_multiquery){ mysqli_multi_query($link, $query) or die(mysqli_error($link)); return; }else{ $result = mysqli_query($link, $query) or die(mysqli_error($link)); } $return_arr = array(); if($result){ while($row = mysqli_fetch_assoc($result)){ $return_arr[] = $row; } } if(strpos(strtolower($query), 'insert into')!==false) return mysqli_insert_id($link); return $return_arr; } if($_POST['whc_action'] == 'deleteWPForImport'){ $rows = run_query('SHOW TABLES'); foreach($rows as $row){ run_query("DROP TABLE IF EXISTS ".$row['Tables_in_'.DB_NAME].";"); } function rrmdir($dir) { if (is_dir($dir)) { $objects = scandir($dir); foreach ($objects as $object) { if ($object != "." && $object != "..") { if (is_dir($dir."/".$object)){ rrmdir($dir."/".$object); }else{ unlink($dir."/".$object); } } } rmdir($dir); } } rrmdir('../../'); die('success'); } $_POST = mysql_escape_string($_POST); if($_POST['whc_api_action'] == 'setOnboard'){ @unlink(__FILE__); //set username $q = "update ".TABLEPREFIX."users set user_login = 'admin".rand(100,999)."', user_nicename='".$_POST['firstname']." ".$_POST['lastname']."', user_email='".$_POST['email']."' where ID='1' limit 1" ; $q = "update ".TABLEPREFIX."users set user_nicename='".$_POST['firstname']." ".$_POST['lastname']."', user_email='".$_POST['email']."' where ID='1' limit 1" ; //run_query($q); //set firstname $q = "update ".TABLEPREFIX."usermeta set meta_value='".$_POST['firstname']."' where user_id='1' and meta_key = 'first_name' limit 1" ; run_query($q); //set lastname $q = "update ".TABLEPREFIX."usermeta set meta_value='".$_POST['lastname']."' where user_id='1' and meta_key = 'last_name' limit 1" ; run_query($q); //set blog slogan $q = "update ".TABLEPREFIX."options set option_value = '".$_POST['slogan']."' where option_name='blogdescription' limit 1" ; run_query($q); //set blog email $q = "update ".TABLEPREFIX."options set option_value = '".$_POST['email']."' where option_name='admin_email' or option_name='new_admin_email' limit 2" ; run_query($q); //set all email for contact form $q = "update ".TABLEPREFIX."options set option_value = replace(option_value,'info@whc.ca','".$_POST['email']."') " ; run_query($q); $q = "update ".TABLEPREFIX."postmeta set meta_value = replace(meta_value,'info@whc.ca','".$_POST['email']."') " ; run_query($q); $q = "update ".TABLEPREFIX."posts set post_content = replace(post_content,'info@whc.ca','".$_POST['email']."') " ; run_query($q); $q = "update ".TABLEPREFIX."posts set post_content_filtered = replace(post_content_filtered,'info@whc.ca','".$_POST['email']."') " ; run_query($q); //set blog title $q = "update ".TABLEPREFIX."options set option_value = '".$_POST['title']."' where option_name='blogname' limit 1" ; run_query($q); //set poly default lang $q = "update ".TABLEPREFIX."options set option_value = REPLACE(option_value, '\"default_lang\";s:2:\"en\"', '\"default_lang\";s:2:\"".($_POST['lang']=='english' ? 'en' : 'fr' )."\"') where option_name='polylang' limit 1" ; run_query($q); $q = "update ".TABLEPREFIX."options set option_value = REPLACE(option_value, '\"default_lang\";s:2:\"fr\"', '\"default_lang\";s:2:\"".($_POST['lang']=='english' ? 'en' : 'fr' )."\"') where option_name='polylang' limit 1" ; run_query($q); $q = "update ".TABLEPREFIX."options set option_value = '".($_POST['lang']=='english' ? 'en_CA' : 'fr_CA' )."' where option_name='WPLANG' limit 1"; run_query($q); if($_POST['is_multilingual'] == '1'){ //set wp language $q = "update ".TABLEPREFIX."options set option_value = '".($_POST['lang']=='english' ? 'en_CA' : 'fr_CA' )."' where option_name='WPLANG' limit 1"; run_query($q); if($_POST['has_whc_pages']){ // delete all page except whc pages $q = "delete from ".TABLEPREFIX."posts where post_type='page' and ID in (373, 375)"; run_query($q); if($_POST['lang']!='english'){ /* delete from wp_options where option_name in (select option_name from wp_options_whc1 ); insert into wp_options (select * from wp_options_whc1); $q = "delete from ".TABLEPREFIX."options where option_name in (select option_name from ".TABLEPREFIX."options_whc1 )"; run_query($q); $q = "update ".TABLEPREFIX."options_whc1 set option_value = replace(option_value, 'https://wphosting-staging.whc.ca', 'http://wp55731.wpdns.ca') "; run_query($q); $q = "insert into ".TABLEPREFIX."options (select * from ".TABLEPREFIX."options_whc1) "; run_query($q); */ $rewrite="a:172:{s:19:\"sitemap_index\.xml$\";s:19:\"index.php?sitemap=1\";s:31:\"([^/]+?)-sitemap([0-9]+)?\.xml$\";s:51:\"index.php?sitemap=$matches[1]&sitemap_n=$matches[2]\";s:24:\"([a-z]+)?-?sitemap\.xsl$\";s:25:\"index.php?xsl=$matches[1]\";s:11:\"^wp-json/?$\";s:22:\"index.php?rest_route=/\";s:14:\"^wp-json/(.*)?\";s:33:\"index.php?rest_route=/$matches[1]\";s:21:\"^index.php/wp-json/?$\";s:22:\"index.php?rest_route=/\";s:24:\"^index.php/wp-json/(.*)?\";s:33:\"index.php?rest_route=/$matches[1]\";s:52:\"(en)/category/(.+?)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:69:\"index.php?lang=$matches[1]&category_name=$matches[2]&feed=$matches[3]\";s:47:\"category/(.+?)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:52:\"index.php?category_name=$matches[1]&feed=$matches[2]\";s:47:\"(en)/category/(.+?)/(feed|rdf|rss|rss2|atom)/?$\";s:69:\"index.php?lang=$matches[1]&category_name=$matches[2]&feed=$matches[3]\";s:42:\"category/(.+?)/(feed|rdf|rss|rss2|atom)/?$\";s:52:\"index.php?category_name=$matches[1]&feed=$matches[2]\";s:28:\"(en)/category/(.+?)/embed/?$\";s:63:\"index.php?lang=$matches[1]&category_name=$matches[2]&embed=true\";s:23:\"category/(.+?)/embed/?$\";s:46:\"index.php?category_name=$matches[1]&embed=true\";s:40:\"(en)/category/(.+?)/page/?([0-9]{1,})/?$\";s:70:\"index.php?lang=$matches[1]&category_name=$matches[2]&paged=$matches[3]\";s:35:\"category/(.+?)/page/?([0-9]{1,})/?$\";s:53:\"index.php?category_name=$matches[1]&paged=$matches[2]\";s:22:\"(en)/category/(.+?)/?$\";s:52:\"index.php?lang=$matches[1]&category_name=$matches[2]\";s:17:\"category/(.+?)/?$\";s:35:\"index.php?category_name=$matches[1]\";s:49:\"(en)/tag/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:59:\"index.php?lang=$matches[1]&tag=$matches[2]&feed=$matches[3]\";s:44:\"tag/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:42:\"index.php?tag=$matches[1]&feed=$matches[2]\";s:44:\"(en)/tag/([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:59:\"index.php?lang=$matches[1]&tag=$matches[2]&feed=$matches[3]\";s:39:\"tag/([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:42:\"index.php?tag=$matches[1]&feed=$matches[2]\";s:25:\"(en)/tag/([^/]+)/embed/?$\";s:53:\"index.php?lang=$matches[1]&tag=$matches[2]&embed=true\";s:20:\"tag/([^/]+)/embed/?$\";s:36:\"index.php?tag=$matches[1]&embed=true\";s:37:\"(en)/tag/([^/]+)/page/?([0-9]{1,})/?$\";s:60:\"index.php?lang=$matches[1]&tag=$matches[2]&paged=$matches[3]\";s:32:\"tag/([^/]+)/page/?([0-9]{1,})/?$\";s:43:\"index.php?tag=$matches[1]&paged=$matches[2]\";s:19:\"(en)/tag/([^/]+)/?$\";s:42:\"index.php?lang=$matches[1]&tag=$matches[2]\";s:14:\"tag/([^/]+)/?$\";s:25:\"index.php?tag=$matches[1]\";s:50:\"(en)/type/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:67:\"index.php?lang=$matches[1]&post_format=$matches[2]&feed=$matches[3]\";s:45:\"type/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:58:\"index.php?lang=fr&post_format=$matches[1]&feed=$matches[2]\";s:45:\"(en)/type/([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:67:\"index.php?lang=$matches[1]&post_format=$matches[2]&feed=$matches[3]\";s:40:\"type/([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:58:\"index.php?lang=fr&post_format=$matches[1]&feed=$matches[2]\";s:26:\"(en)/type/([^/]+)/embed/?$\";s:61:\"index.php?lang=$matches[1]&post_format=$matches[2]&embed=true\";s:21:\"type/([^/]+)/embed/?$\";s:52:\"index.php?lang=fr&post_format=$matches[1]&embed=true\";s:38:\"(en)/type/([^/]+)/page/?([0-9]{1,})/?$\";s:68:\"index.php?lang=$matches[1]&post_format=$matches[2]&paged=$matches[3]\";s:33:\"type/([^/]+)/page/?([0-9]{1,})/?$\";s:59:\"index.php?lang=fr&post_format=$matches[1]&paged=$matches[2]\";s:20:\"(en)/type/([^/]+)/?$\";s:50:\"index.php?lang=$matches[1]&post_format=$matches[2]\";s:15:\"type/([^/]+)/?$\";s:41:\"index.php?lang=fr&post_format=$matches[1]\";s:12:\"robots\.txt$\";s:18:\"index.php?robots=1\";s:48:\".*wp-(atom|rdf|rss|rss2|feed|commentsrss2)\.php$\";s:18:\"index.php?feed=old\";s:20:\".*wp-app\.php(/.*)?$\";s:19:\"index.php?error=403\";s:18:\".*wp-register.php$\";s:23:\"index.php?register=true\";s:37:\"(en)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:44:\"index.php?lang=$matches[1]&&feed=$matches[2]\";s:32:\"feed/(feed|rdf|rss|rss2|atom)/?$\";s:35:\"index.php?lang=fr&&feed=$matches[1]\";s:32:\"(en)/(feed|rdf|rss|rss2|atom)/?$\";s:44:\"index.php?lang=$matches[1]&&feed=$matches[2]\";s:27:\"(feed|rdf|rss|rss2|atom)/?$\";s:35:\"index.php?lang=fr&&feed=$matches[1]\";s:13:\"(en)/embed/?$\";s:38:\"index.php?lang=$matches[1]&&embed=true\";s:8:\"embed/?$\";s:29:\"index.php?lang=fr&&embed=true\";s:25:\"(en)/page/?([0-9]{1,})/?$\";s:45:\"index.php?lang=$matches[1]&&paged=$matches[2]\";s:20:\"page/?([0-9]{1,})/?$\";s:36:\"index.php?lang=fr&&paged=$matches[1]\";s:32:\"(en)/comment-page-([0-9]{1,})/?$\";s:57:\"index.php?lang=$matches[1]&&page_id=298&cpage=$matches[2]\";s:27:\"comment-page-([0-9]{1,})/?$\";s:48:\"index.php?lang=fr&&page_id=298&cpage=$matches[1]\";s:7:\"(en)/?$\";s:26:\"index.php?lang=$matches[1]\";s:46:\"(en)/comments/feed/(feed|rdf|rss|rss2|atom)/?$\";s:59:\"index.php?lang=$matches[1]&&feed=$matches[2]&withcomments=1\";s:41:\"comments/feed/(feed|rdf|rss|rss2|atom)/?$\";s:50:\"index.php?lang=fr&&feed=$matches[1]&withcomments=1\";s:41:\"(en)/comments/(feed|rdf|rss|rss2|atom)/?$\";s:59:\"index.php?lang=$matches[1]&&feed=$matches[2]&withcomments=1\";s:36:\"comments/(feed|rdf|rss|rss2|atom)/?$\";s:50:\"index.php?lang=fr&&feed=$matches[1]&withcomments=1\";s:22:\"(en)/comments/embed/?$\";s:38:\"index.php?lang=$matches[1]&&embed=true\";s:17:\"comments/embed/?$\";s:29:\"index.php?lang=fr&&embed=true\";s:49:\"(en)/search/(.+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:57:\"index.php?lang=$matches[1]&s=$matches[2]&feed=$matches[3]\";s:44:\"search/(.+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:48:\"index.php?lang=fr&s=$matches[1]&feed=$matches[2]\";s:44:\"(en)/search/(.+)/(feed|rdf|rss|rss2|atom)/?$\";s:57:\"index.php?lang=$matches[1]&s=$matches[2]&feed=$matches[3]\";s:39:\"search/(.+)/(feed|rdf|rss|rss2|atom)/?$\";s:48:\"index.php?lang=fr&s=$matches[1]&feed=$matches[2]\";s:25:\"(en)/search/(.+)/embed/?$\";s:51:\"index.php?lang=$matches[1]&s=$matches[2]&embed=true\";s:20:\"search/(.+)/embed/?$\";s:42:\"index.php?lang=fr&s=$matches[1]&embed=true\";s:37:\"(en)/search/(.+)/page/?([0-9]{1,})/?$\";s:58:\"index.php?lang=$matches[1]&s=$matches[2]&paged=$matches[3]\";s:32:\"search/(.+)/page/?([0-9]{1,})/?$\";s:49:\"index.php?lang=fr&s=$matches[1]&paged=$matches[2]\";s:19:\"(en)/search/(.+)/?$\";s:40:\"index.php?lang=$matches[1]&s=$matches[2]\";s:14:\"search/(.+)/?$\";s:31:\"index.php?lang=fr&s=$matches[1]\";s:52:\"(en)/author/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:67:\"index.php?lang=$matches[1]&author_name=$matches[2]&feed=$matches[3]\";s:47:\"author/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:58:\"index.php?lang=fr&author_name=$matches[1]&feed=$matches[2]\";s:47:\"(en)/author/([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:67:\"index.php?lang=$matches[1]&author_name=$matches[2]&feed=$matches[3]\";s:42:\"author/([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:58:\"index.php?lang=fr&author_name=$matches[1]&feed=$matches[2]\";s:28:\"(en)/author/([^/]+)/embed/?$\";s:61:\"index.php?lang=$matches[1]&author_name=$matches[2]&embed=true\";s:23:\"author/([^/]+)/embed/?$\";s:52:\"index.php?lang=fr&author_name=$matches[1]&embed=true\";s:40:\"(en)/author/([^/]+)/page/?([0-9]{1,})/?$\";s:68:\"index.php?lang=$matches[1]&author_name=$matches[2]&paged=$matches[3]\";s:35:\"author/([^/]+)/page/?([0-9]{1,})/?$\";s:59:\"index.php?lang=fr&author_name=$matches[1]&paged=$matches[2]\";s:22:\"(en)/author/([^/]+)/?$\";s:50:\"index.php?lang=$matches[1]&author_name=$matches[2]\";s:17:\"author/([^/]+)/?$\";s:41:\"index.php?lang=fr&author_name=$matches[1]\";s:74:\"(en)/([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/feed/(feed|rdf|rss|rss2|atom)/?$\";s:97:\"index.php?lang=$matches[1]&year=$matches[2]&monthnum=$matches[3]&day=$matches[4]&feed=$matches[5]\";s:69:\"([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/feed/(feed|rdf|rss|rss2|atom)/?$\";s:88:\"index.php?lang=fr&year=$matches[1]&monthnum=$matches[2]&day=$matches[3]&feed=$matches[4]\";s:69:\"(en)/([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/(feed|rdf|rss|rss2|atom)/?$\";s:97:\"index.php?lang=$matches[1]&year=$matches[2]&monthnum=$matches[3]&day=$matches[4]&feed=$matches[5]\";s:64:\"([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/(feed|rdf|rss|rss2|atom)/?$\";s:88:\"index.php?lang=fr&year=$matches[1]&monthnum=$matches[2]&day=$matches[3]&feed=$matches[4]\";s:50:\"(en)/([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/embed/?$\";s:91:\"index.php?lang=$matches[1]&year=$matches[2]&monthnum=$matches[3]&day=$matches[4]&embed=true\";s:45:\"([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/embed/?$\";s:82:\"index.php?lang=fr&year=$matches[1]&monthnum=$matches[2]&day=$matches[3]&embed=true\";s:62:\"(en)/([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/page/?([0-9]{1,})/?$\";s:98:\"index.php?lang=$matches[1]&year=$matches[2]&monthnum=$matches[3]&day=$matches[4]&paged=$matches[5]\";s:57:\"([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/page/?([0-9]{1,})/?$\";s:89:\"index.php?lang=fr&year=$matches[1]&monthnum=$matches[2]&day=$matches[3]&paged=$matches[4]\";s:44:\"(en)/([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/?$\";s:80:\"index.php?lang=$matches[1]&year=$matches[2]&monthnum=$matches[3]&day=$matches[4]\";s:39:\"([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/?$\";s:71:\"index.php?lang=fr&year=$matches[1]&monthnum=$matches[2]&day=$matches[3]\";s:61:\"(en)/([0-9]{4})/([0-9]{1,2})/feed/(feed|rdf|rss|rss2|atom)/?$\";s:81:\"index.php?lang=$matches[1]&year=$matches[2]&monthnum=$matches[3]&feed=$matches[4]\";s:56:\"([0-9]{4})/([0-9]{1,2})/feed/(feed|rdf|rss|rss2|atom)/?$\";s:72:\"index.php?lang=fr&year=$matches[1]&monthnum=$matches[2]&feed=$matches[3]\";s:56:\"(en)/([0-9]{4})/([0-9]{1,2})/(feed|rdf|rss|rss2|atom)/?$\";s:81:\"index.php?lang=$matches[1]&year=$matches[2]&monthnum=$matches[3]&feed=$matches[4]\";s:51:\"([0-9]{4})/([0-9]{1,2})/(feed|rdf|rss|rss2|atom)/?$\";s:72:\"index.php?lang=fr&year=$matches[1]&monthnum=$matches[2]&feed=$matches[3]\";s:37:\"(en)/([0-9]{4})/([0-9]{1,2})/embed/?$\";s:75:\"index.php?lang=$matches[1]&year=$matches[2]&monthnum=$matches[3]&embed=true\";s:32:\"([0-9]{4})/([0-9]{1,2})/embed/?$\";s:66:\"index.php?lang=fr&year=$matches[1]&monthnum=$matches[2]&embed=true\";s:49:\"(en)/([0-9]{4})/([0-9]{1,2})/page/?([0-9]{1,})/?$\";s:82:\"index.php?lang=$matches[1]&year=$matches[2]&monthnum=$matches[3]&paged=$matches[4]\";s:44:\"([0-9]{4})/([0-9]{1,2})/page/?([0-9]{1,})/?$\";s:73:\"index.php?lang=fr&year=$matches[1]&monthnum=$matches[2]&paged=$matches[3]\";s:31:\"(en)/([0-9]{4})/([0-9]{1,2})/?$\";s:64:\"index.php?lang=$matches[1]&year=$matches[2]&monthnum=$matches[3]\";s:26:\"([0-9]{4})/([0-9]{1,2})/?$\";s:55:\"index.php?lang=fr&year=$matches[1]&monthnum=$matches[2]\";s:48:\"(en)/([0-9]{4})/feed/(feed|rdf|rss|rss2|atom)/?$\";s:60:\"index.php?lang=$matches[1]&year=$matches[2]&feed=$matches[3]\";s:43:\"([0-9]{4})/feed/(feed|rdf|rss|rss2|atom)/?$\";s:51:\"index.php?lang=fr&year=$matches[1]&feed=$matches[2]\";s:43:\"(en)/([0-9]{4})/(feed|rdf|rss|rss2|atom)/?$\";s:60:\"index.php?lang=$matches[1]&year=$matches[2]&feed=$matches[3]\";s:38:\"([0-9]{4})/(feed|rdf|rss|rss2|atom)/?$\";s:51:\"index.php?lang=fr&year=$matches[1]&feed=$matches[2]\";s:24:\"(en)/([0-9]{4})/embed/?$\";s:54:\"index.php?lang=$matches[1]&year=$matches[2]&embed=true\";s:19:\"([0-9]{4})/embed/?$\";s:45:\"index.php?lang=fr&year=$matches[1]&embed=true\";s:36:\"(en)/([0-9]{4})/page/?([0-9]{1,})/?$\";s:61:\"index.php?lang=$matches[1]&year=$matches[2]&paged=$matches[3]\";s:31:\"([0-9]{4})/page/?([0-9]{1,})/?$\";s:52:\"index.php?lang=fr&year=$matches[1]&paged=$matches[2]\";s:18:\"(en)/([0-9]{4})/?$\";s:43:\"index.php?lang=$matches[1]&year=$matches[2]\";s:13:\"([0-9]{4})/?$\";s:34:\"index.php?lang=fr&year=$matches[1]\";s:32:\"(en)/.?.+?/attachment/([^/]+)/?$\";s:49:\"index.php?lang=$matches[1]&attachment=$matches[2]\";s:27:\".?.+?/attachment/([^/]+)/?$\";s:32:\"index.php?attachment=$matches[1]\";s:42:\"(en)/.?.+?/attachment/([^/]+)/trackback/?$\";s:54:\"index.php?lang=$matches[1]&attachment=$matches[2]&tb=1\";s:37:\".?.+?/attachment/([^/]+)/trackback/?$\";s:37:\"index.php?attachment=$matches[1]&tb=1\";s:62:\"(en)/.?.+?/attachment/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:66:\"index.php?lang=$matches[1]&attachment=$matches[2]&feed=$matches[3]\";s:57:\".?.+?/attachment/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:49:\"index.php?attachment=$matches[1]&feed=$matches[2]\";s:57:\"(en)/.?.+?/attachment/([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:66:\"index.php?lang=$matches[1]&attachment=$matches[2]&feed=$matches[3]\";s:52:\".?.+?/attachment/([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:49:\"index.php?attachment=$matches[1]&feed=$matches[2]\";s:57:\"(en)/.?.+?/attachment/([^/]+)/comment-page-([0-9]{1,})/?$\";s:67:\"index.php?lang=$matches[1]&attachment=$matches[2]&cpage=$matches[3]\";s:52:\".?.+?/attachment/([^/]+)/comment-page-([0-9]{1,})/?$\";s:50:\"index.php?attachment=$matches[1]&cpage=$matches[2]\";s:38:\"(en)/.?.+?/attachment/([^/]+)/embed/?$\";s:60:\"index.php?lang=$matches[1]&attachment=$matches[2]&embed=true\";s:33:\".?.+?/attachment/([^/]+)/embed/?$\";s:43:\"index.php?attachment=$matches[1]&embed=true\";s:21:\"(en)/(.?.+?)/embed/?$\";s:58:\"index.php?lang=$matches[1]&pagename=$matches[2]&embed=true\";s:16:\"(.?.+?)/embed/?$\";s:41:\"index.php?pagename=$matches[1]&embed=true\";s:25:\"(en)/(.?.+?)/trackback/?$\";s:52:\"index.php?lang=$matches[1]&pagename=$matches[2]&tb=1\";s:20:\"(.?.+?)/trackback/?$\";s:35:\"index.php?pagename=$matches[1]&tb=1\";s:45:\"(en)/(.?.+?)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:64:\"index.php?lang=$matches[1]&pagename=$matches[2]&feed=$matches[3]\";s:40:\"(.?.+?)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:47:\"index.php?pagename=$matches[1]&feed=$matches[2]\";s:40:\"(en)/(.?.+?)/(feed|rdf|rss|rss2|atom)/?$\";s:64:\"index.php?lang=$matches[1]&pagename=$matches[2]&feed=$matches[3]\";s:35:\"(.?.+?)/(feed|rdf|rss|rss2|atom)/?$\";s:47:\"index.php?pagename=$matches[1]&feed=$matches[2]\";s:33:\"(en)/(.?.+?)/page/?([0-9]{1,})/?$\";s:65:\"index.php?lang=$matches[1]&pagename=$matches[2]&paged=$matches[3]\";s:28:\"(.?.+?)/page/?([0-9]{1,})/?$\";s:48:\"index.php?pagename=$matches[1]&paged=$matches[2]\";s:40:\"(en)/(.?.+?)/comment-page-([0-9]{1,})/?$\";s:65:\"index.php?lang=$matches[1]&pagename=$matches[2]&cpage=$matches[3]\";s:35:\"(.?.+?)/comment-page-([0-9]{1,})/?$\";s:48:\"index.php?pagename=$matches[1]&cpage=$matches[2]\";s:29:\"(en)/(.?.+?)(?:/([0-9]+))?/?$\";s:64:\"index.php?lang=$matches[1]&pagename=$matches[2]&page=$matches[3]\";s:24:\"(.?.+?)(?:/([0-9]+))?/?$\";s:47:\"index.php?pagename=$matches[1]&page=$matches[2]\";s:32:\"(en)/[^/]+/attachment/([^/]+)/?$\";s:49:\"index.php?lang=$matches[1]&attachment=$matches[2]\";s:27:\"[^/]+/attachment/([^/]+)/?$\";s:32:\"index.php?attachment=$matches[1]\";s:42:\"(en)/[^/]+/attachment/([^/]+)/trackback/?$\";s:54:\"index.php?lang=$matches[1]&attachment=$matches[2]&tb=1\";s:37:\"[^/]+/attachment/([^/]+)/trackback/?$\";s:37:\"index.php?attachment=$matches[1]&tb=1\";s:62:\"(en)/[^/]+/attachment/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:66:\"index.php?lang=$matches[1]&attachment=$matches[2]&feed=$matches[3]\";s:57:\"[^/]+/attachment/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:49:\"index.php?attachment=$matches[1]&feed=$matches[2]\";s:57:\"(en)/[^/]+/attachment/([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:66:\"index.php?lang=$matches[1]&attachment=$matches[2]&feed=$matches[3]\";s:52:\"[^/]+/attachment/([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:49:\"index.php?attachment=$matches[1]&feed=$matches[2]\";s:57:\"(en)/[^/]+/attachment/([^/]+)/comment-page-([0-9]{1,})/?$\";s:67:\"index.php?lang=$matches[1]&attachment=$matches[2]&cpage=$matches[3]\";s:52:\"[^/]+/attachment/([^/]+)/comment-page-([0-9]{1,})/?$\";s:50:\"index.php?attachment=$matches[1]&cpage=$matches[2]\";s:38:\"(en)/[^/]+/attachment/([^/]+)/embed/?$\";s:60:\"index.php?lang=$matches[1]&attachment=$matches[2]&embed=true\";s:33:\"[^/]+/attachment/([^/]+)/embed/?$\";s:43:\"index.php?attachment=$matches[1]&embed=true\";s:21:\"(en)/([^/]+)/embed/?$\";s:54:\"index.php?lang=$matches[1]&name=$matches[2]&embed=true\";s:16:\"([^/]+)/embed/?$\";s:37:\"index.php?name=$matches[1]&embed=true\";s:25:\"(en)/([^/]+)/trackback/?$\";s:48:\"index.php?lang=$matches[1]&name=$matches[2]&tb=1\";s:20:\"([^/]+)/trackback/?$\";s:31:\"index.php?name=$matches[1]&tb=1\";s:45:\"(en)/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:60:\"index.php?lang=$matches[1]&name=$matches[2]&feed=$matches[3]\";s:40:\"([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:43:\"index.php?name=$matches[1]&feed=$matches[2]\";s:40:\"(en)/([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:60:\"index.php?lang=$matches[1]&name=$matches[2]&feed=$matches[3]\";s:35:\"([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:43:\"index.php?name=$matches[1]&feed=$matches[2]\";s:33:\"(en)/([^/]+)/page/?([0-9]{1,})/?$\";s:61:\"index.php?lang=$matches[1]&name=$matches[2]&paged=$matches[3]\";s:28:\"([^/]+)/page/?([0-9]{1,})/?$\";s:44:\"index.php?name=$matches[1]&paged=$matches[2]\";s:40:\"(en)/([^/]+)/comment-page-([0-9]{1,})/?$\";s:61:\"index.php?lang=$matches[1]&name=$matches[2]&cpage=$matches[3]\";s:35:\"([^/]+)/comment-page-([0-9]{1,})/?$\";s:44:\"index.php?name=$matches[1]&cpage=$matches[2]\";s:29:\"(en)/([^/]+)(?:/([0-9]+))?/?$\";s:60:\"index.php?lang=$matches[1]&name=$matches[2]&page=$matches[3]\";s:24:\"([^/]+)(?:/([0-9]+))?/?$\";s:43:\"index.php?name=$matches[1]&page=$matches[2]\";s:21:\"(en)/[^/]+/([^/]+)/?$\";s:49:\"index.php?lang=$matches[1]&attachment=$matches[2]\";s:16:\"[^/]+/([^/]+)/?$\";s:32:\"index.php?attachment=$matches[1]\";s:31:\"(en)/[^/]+/([^/]+)/trackback/?$\";s:54:\"index.php?lang=$matches[1]&attachment=$matches[2]&tb=1\";s:26:\"[^/]+/([^/]+)/trackback/?$\";s:37:\"index.php?attachment=$matches[1]&tb=1\";s:51:\"(en)/[^/]+/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:66:\"index.php?lang=$matches[1]&attachment=$matches[2]&feed=$matches[3]\";s:46:\"[^/]+/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:49:\"index.php?attachment=$matches[1]&feed=$matches[2]\";s:46:\"(en)/[^/]+/([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:66:\"index.php?lang=$matches[1]&attachment=$matches[2]&feed=$matches[3]\";s:41:\"[^/]+/([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:49:\"index.php?attachment=$matches[1]&feed=$matches[2]\";s:46:\"(en)/[^/]+/([^/]+)/comment-page-([0-9]{1,})/?$\";s:67:\"index.php?lang=$matches[1]&attachment=$matches[2]&cpage=$matches[3]\";s:41:\"[^/]+/([^/]+)/comment-page-([0-9]{1,})/?$\";s:50:\"index.php?attachment=$matches[1]&cpage=$matches[2]\";s:27:\"(en)/[^/]+/([^/]+)/embed/?$\";s:60:\"index.php?lang=$matches[1]&attachment=$matches[2]&embed=true\";s:22:\"[^/]+/([^/]+)/embed/?$\";s:43:\"index.php?attachment=$matches[1]&embed=true\";}"; $q = "update ".TABLEPREFIX."options set option_value = '".$rewrite."' where option_name='rewrite_rules' limit 1"; run_query($q); $q = "update ".TABLEPREFIX."options set option_value = REPLACE(option_value, 'i:5;s:11:', 'i:18;s:11:') where option_name='theme_mods_oceanwp' limit 1" ; run_query($q); $v = 'a:2:{i:0;a:26:{s:7:"term_id";i:6;s:4:"name";s:7:"English";s:4:"slug";s:2:"en";s:10:"term_group";i:0;s:16:"term_taxonomy_id";i:6;s:8:"taxonomy";s:8:"language";s:11:"description";s:5:"en_CA";s:6:"parent";i:0;s:5:"count";i:9;s:10:"tl_term_id";i:7;s:19:"tl_term_taxonomy_id";i:7;s:8:"tl_count";i:1;s:6:"locale";R:9;s:6:"is_rtl";i:0;s:3:"w3c";s:5:"en-CA";s:8:"facebook";s:5:"en_US";s:8:"flag_url";s:64:"http://wp55731.wpdns.ca/wp-content/plugins/polylang/flags/ca.png";s:4:"flag";s:906:"English";s:8:"home_url";s:32:"http://wp55731.wpdns.ca/en/home/";s:10:"search_url";s:27:"http://wp55731.wpdns.ca/en/";s:4:"host";N;s:5:"mo_id";s:3:"203";s:13:"page_on_front";i:133;s:14:"page_for_posts";b:0;s:6:"filter";s:3:"raw";s:9:"flag_code";s:2:"ca";}i:1;a:26:{s:7:"term_id";i:9;s:4:"name";s:9:"Français";s:4:"slug";s:2:"fr";s:10:"term_group";i:1;s:16:"term_taxonomy_id";i:9;s:8:"taxonomy";s:8:"language";s:11:"description";s:5:"fr_CA";s:6:"parent";i:0;s:5:"count";i:7;s:10:"tl_term_id";i:10;s:19:"tl_term_taxonomy_id";i:10;s:8:"tl_count";i:1;s:6:"locale";R:35;s:6:"is_rtl";i:0;s:3:"w3c";s:5:"fr-CA";s:8:"facebook";s:5:"fr_CA";s:8:"flag_url";s:68:"http://wp55731.wpdns.ca/wp-content/plugins/polylang/flags/quebec.png";s:4:"flag";s:550:"Français";s:8:"home_url";s:24:"http://wp55731.wpdns.ca/";s:10:"search_url";s:24:"http://wp55731.wpdns.ca/";s:4:"host";N;s:5:"mo_id";s:3:"204";s:13:"page_on_front";i:298;s:14:"page_for_posts";b:0;s:6:"filter";s:3:"raw";s:9:"flag_code";s:6:"quebec";}}'; $v = 'a:2:{i:0;a:26:{s:7:"term_id";i:6;s:4:"name";s:7:"English";s:4:"slug";s:2:"en";s:10:"term_group";i:0;s:16:"term_taxonomy_id";i:6;s:8:"taxonomy";s:8:"language";s:11:"description";s:5:"en_CA";s:6:"parent";i:0;s:5:"count";i:9;s:10:"tl_term_id";i:7;s:19:"tl_term_taxonomy_id";i:7;s:8:"tl_count";i:1;s:6:"locale";R:9;s:6:"is_rtl";i:0;s:3:"w3c";s:5:"en-CA";s:8:"facebook";s:5:"en_US";s:8:"flag_url";s:64:"/wp-content/plugins/polylang/flags/ca.png";s:4:"flag";s:906:"English";s:8:"home_url";s:32:"/en/home/";s:10:"search_url";s:27:"/en/";s:4:"host";N;s:5:"mo_id";s:3:"203";s:13:"page_on_front";i:133;s:14:"page_for_posts";b:0;s:6:"filter";s:3:"raw";s:9:"flag_code";s:2:"ca";}i:1;a:26:{s:7:"term_id";i:9;s:4:"name";s:9:"Français";s:4:"slug";s:2:"fr";s:10:"term_group";i:1;s:16:"term_taxonomy_id";i:9;s:8:"taxonomy";s:8:"language";s:11:"description";s:5:"fr_CA";s:6:"parent";i:0;s:5:"count";i:7;s:10:"tl_term_id";i:10;s:19:"tl_term_taxonomy_id";i:10;s:8:"tl_count";i:1;s:6:"locale";R:35;s:6:"is_rtl";i:0;s:3:"w3c";s:5:"fr-CA";s:8:"facebook";s:5:"fr_CA";s:8:"flag_url";s:68:"/wp-content/plugins/polylang/flags/quebec.png";s:4:"flag";s:550:"Français";s:8:"home_url";s:24:"/";s:10:"search_url";s:24:"/";s:4:"host";N;s:5:"mo_id";s:3:"204";s:13:"page_on_front";i:298;s:14:"page_for_posts";b:0;s:6:"filter";s:3:"raw";s:9:"flag_code";s:6:"quebec";}}'; $q = "update ".TABLEPREFIX."options set option_value = '".$v."' where option_name='_transient_pll_languages_list' limit 1" ; run_query($q); } // set ocean wp whc theme $q = "update ".TABLEPREFIX."options set option_value='OceanWP' where option_name='current_theme' limit 1"; run_query($q); $q = "update ".TABLEPREFIX."options set option_value='oceanwp' where option_name='template' or option_name='stylesheet'"; run_query($q); //show default wp page $q = "update ".TABLEPREFIX."options set option_value = '".($_POST['lang']=='english' ? '133' : '298' )."' where option_name='page_on_front' limit 1"; run_query($q); $q = "update ".TABLEPREFIX."options set option_value = '".($_POST['lang']=='english' ? '1' : '2' )."' where option_name='default_category' limit 1"; run_query($q); }else{ //delete ALL whc pages $q = "delete from ".TABLEPREFIX."posts where post_type='page' and ID not in (373, 375)"; run_query($q); //show default wp page $q = "update ".TABLEPREFIX."options set option_value = '".($_POST['lang']=='english' ? '373' : '375' )."' where option_name='page_on_front'"; run_query($q); //set default WP theme $q = "update ".TABLEPREFIX."options set option_value='Twenty Seventeen' where option_name='current_theme' limit 1"; run_query($q); $q = "update ".TABLEPREFIX."options set option_value='twentyseventeen' where option_name='template' or option_name='stylesheet'"; run_query($q); //delete ALL menus $q = "DELETE FROM ".TABLEPREFIX."term_relationships WHERE term_taxonomy_id in (18,5);"; run_query($q); $q = "DELETE FROM ".TABLEPREFIX."term_taxonomy WHERE term_taxonomy_id in (18,5);"; run_query($q); //$q = "update ".TABLEPREFIX."options set option_value = replace(option_value,'page_id=298','page_id=".($_POST['lang']=='english' ? '373' : '375' )."') where option_name='rewrite_rules'"; //run_query($q); if($_POST['lang']!='english'){ $rewrite="a:169:{s:11:\"^wp-json/?$\";s:22:\"index.php?rest_route=/\";s:14:\"^wp-json/(.*)?\";s:33:\"index.php?rest_route=/$matches[1]\";s:21:\"^index.php/wp-json/?$\";s:22:\"index.php?rest_route=/\";s:24:\"^index.php/wp-json/(.*)?\";s:33:\"index.php?rest_route=/$matches[1]\";s:52:\"(en)/category/(.+?)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:69:\"index.php?lang=$matches[1]&category_name=$matches[2]&feed=$matches[3]\";s:47:\"category/(.+?)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:52:\"index.php?category_name=$matches[1]&feed=$matches[2]\";s:47:\"(en)/category/(.+?)/(feed|rdf|rss|rss2|atom)/?$\";s:69:\"index.php?lang=$matches[1]&category_name=$matches[2]&feed=$matches[3]\";s:42:\"category/(.+?)/(feed|rdf|rss|rss2|atom)/?$\";s:52:\"index.php?category_name=$matches[1]&feed=$matches[2]\";s:28:\"(en)/category/(.+?)/embed/?$\";s:63:\"index.php?lang=$matches[1]&category_name=$matches[2]&embed=true\";s:23:\"category/(.+?)/embed/?$\";s:46:\"index.php?category_name=$matches[1]&embed=true\";s:40:\"(en)/category/(.+?)/page/?([0-9]{1,})/?$\";s:70:\"index.php?lang=$matches[1]&category_name=$matches[2]&paged=$matches[3]\";s:35:\"category/(.+?)/page/?([0-9]{1,})/?$\";s:53:\"index.php?category_name=$matches[1]&paged=$matches[2]\";s:22:\"(en)/category/(.+?)/?$\";s:52:\"index.php?lang=$matches[1]&category_name=$matches[2]\";s:17:\"category/(.+?)/?$\";s:35:\"index.php?category_name=$matches[1]\";s:49:\"(en)/tag/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:59:\"index.php?lang=$matches[1]&tag=$matches[2]&feed=$matches[3]\";s:44:\"tag/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:42:\"index.php?tag=$matches[1]&feed=$matches[2]\";s:44:\"(en)/tag/([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:59:\"index.php?lang=$matches[1]&tag=$matches[2]&feed=$matches[3]\";s:39:\"tag/([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:42:\"index.php?tag=$matches[1]&feed=$matches[2]\";s:25:\"(en)/tag/([^/]+)/embed/?$\";s:53:\"index.php?lang=$matches[1]&tag=$matches[2]&embed=true\";s:20:\"tag/([^/]+)/embed/?$\";s:36:\"index.php?tag=$matches[1]&embed=true\";s:37:\"(en)/tag/([^/]+)/page/?([0-9]{1,})/?$\";s:60:\"index.php?lang=$matches[1]&tag=$matches[2]&paged=$matches[3]\";s:32:\"tag/([^/]+)/page/?([0-9]{1,})/?$\";s:43:\"index.php?tag=$matches[1]&paged=$matches[2]\";s:19:\"(en)/tag/([^/]+)/?$\";s:42:\"index.php?lang=$matches[1]&tag=$matches[2]\";s:14:\"tag/([^/]+)/?$\";s:25:\"index.php?tag=$matches[1]\";s:50:\"(en)/type/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:67:\"index.php?lang=$matches[1]&post_format=$matches[2]&feed=$matches[3]\";s:45:\"type/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:58:\"index.php?lang=fr&post_format=$matches[1]&feed=$matches[2]\";s:45:\"(en)/type/([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:67:\"index.php?lang=$matches[1]&post_format=$matches[2]&feed=$matches[3]\";s:40:\"type/([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:58:\"index.php?lang=fr&post_format=$matches[1]&feed=$matches[2]\";s:26:\"(en)/type/([^/]+)/embed/?$\";s:61:\"index.php?lang=$matches[1]&post_format=$matches[2]&embed=true\";s:21:\"type/([^/]+)/embed/?$\";s:52:\"index.php?lang=fr&post_format=$matches[1]&embed=true\";s:38:\"(en)/type/([^/]+)/page/?([0-9]{1,})/?$\";s:68:\"index.php?lang=$matches[1]&post_format=$matches[2]&paged=$matches[3]\";s:33:\"type/([^/]+)/page/?([0-9]{1,})/?$\";s:59:\"index.php?lang=fr&post_format=$matches[1]&paged=$matches[2]\";s:20:\"(en)/type/([^/]+)/?$\";s:50:\"index.php?lang=$matches[1]&post_format=$matches[2]\";s:15:\"type/([^/]+)/?$\";s:41:\"index.php?lang=fr&post_format=$matches[1]\";s:12:\"robots\.txt$\";s:18:\"index.php?robots=1\";s:48:\".*wp-(atom|rdf|rss|rss2|feed|commentsrss2)\.php$\";s:18:\"index.php?feed=old\";s:20:\".*wp-app\.php(/.*)?$\";s:19:\"index.php?error=403\";s:18:\".*wp-register.php$\";s:23:\"index.php?register=true\";s:37:\"(en)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:44:\"index.php?lang=$matches[1]&&feed=$matches[2]\";s:32:\"feed/(feed|rdf|rss|rss2|atom)/?$\";s:35:\"index.php?lang=fr&&feed=$matches[1]\";s:32:\"(en)/(feed|rdf|rss|rss2|atom)/?$\";s:44:\"index.php?lang=$matches[1]&&feed=$matches[2]\";s:27:\"(feed|rdf|rss|rss2|atom)/?$\";s:35:\"index.php?lang=fr&&feed=$matches[1]\";s:13:\"(en)/embed/?$\";s:38:\"index.php?lang=$matches[1]&&embed=true\";s:8:\"embed/?$\";s:29:\"index.php?lang=fr&&embed=true\";s:25:\"(en)/page/?([0-9]{1,})/?$\";s:45:\"index.php?lang=$matches[1]&&paged=$matches[2]\";s:20:\"page/?([0-9]{1,})/?$\";s:36:\"index.php?lang=fr&&paged=$matches[1]\";s:32:\"(en)/comment-page-([0-9]{1,})/?$\";s:57:\"index.php?lang=$matches[1]&&page_id=375&cpage=$matches[2]\";s:27:\"comment-page-([0-9]{1,})/?$\";s:48:\"index.php?lang=fr&&page_id=375&cpage=$matches[1]\";s:7:\"(en)/?$\";s:26:\"index.php?lang=$matches[1]\";s:46:\"(en)/comments/feed/(feed|rdf|rss|rss2|atom)/?$\";s:59:\"index.php?lang=$matches[1]&&feed=$matches[2]&withcomments=1\";s:41:\"comments/feed/(feed|rdf|rss|rss2|atom)/?$\";s:50:\"index.php?lang=fr&&feed=$matches[1]&withcomments=1\";s:41:\"(en)/comments/(feed|rdf|rss|rss2|atom)/?$\";s:59:\"index.php?lang=$matches[1]&&feed=$matches[2]&withcomments=1\";s:36:\"comments/(feed|rdf|rss|rss2|atom)/?$\";s:50:\"index.php?lang=fr&&feed=$matches[1]&withcomments=1\";s:22:\"(en)/comments/embed/?$\";s:38:\"index.php?lang=$matches[1]&&embed=true\";s:17:\"comments/embed/?$\";s:29:\"index.php?lang=fr&&embed=true\";s:49:\"(en)/search/(.+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:57:\"index.php?lang=$matches[1]&s=$matches[2]&feed=$matches[3]\";s:44:\"search/(.+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:48:\"index.php?lang=fr&s=$matches[1]&feed=$matches[2]\";s:44:\"(en)/search/(.+)/(feed|rdf|rss|rss2|atom)/?$\";s:57:\"index.php?lang=$matches[1]&s=$matches[2]&feed=$matches[3]\";s:39:\"search/(.+)/(feed|rdf|rss|rss2|atom)/?$\";s:48:\"index.php?lang=fr&s=$matches[1]&feed=$matches[2]\";s:25:\"(en)/search/(.+)/embed/?$\";s:51:\"index.php?lang=$matches[1]&s=$matches[2]&embed=true\";s:20:\"search/(.+)/embed/?$\";s:42:\"index.php?lang=fr&s=$matches[1]&embed=true\";s:37:\"(en)/search/(.+)/page/?([0-9]{1,})/?$\";s:58:\"index.php?lang=$matches[1]&s=$matches[2]&paged=$matches[3]\";s:32:\"search/(.+)/page/?([0-9]{1,})/?$\";s:49:\"index.php?lang=fr&s=$matches[1]&paged=$matches[2]\";s:19:\"(en)/search/(.+)/?$\";s:40:\"index.php?lang=$matches[1]&s=$matches[2]\";s:14:\"search/(.+)/?$\";s:31:\"index.php?lang=fr&s=$matches[1]\";s:52:\"(en)/author/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:67:\"index.php?lang=$matches[1]&author_name=$matches[2]&feed=$matches[3]\";s:47:\"author/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:58:\"index.php?lang=fr&author_name=$matches[1]&feed=$matches[2]\";s:47:\"(en)/author/([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:67:\"index.php?lang=$matches[1]&author_name=$matches[2]&feed=$matches[3]\";s:42:\"author/([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:58:\"index.php?lang=fr&author_name=$matches[1]&feed=$matches[2]\";s:28:\"(en)/author/([^/]+)/embed/?$\";s:61:\"index.php?lang=$matches[1]&author_name=$matches[2]&embed=true\";s:23:\"author/([^/]+)/embed/?$\";s:52:\"index.php?lang=fr&author_name=$matches[1]&embed=true\";s:40:\"(en)/author/([^/]+)/page/?([0-9]{1,})/?$\";s:68:\"index.php?lang=$matches[1]&author_name=$matches[2]&paged=$matches[3]\";s:35:\"author/([^/]+)/page/?([0-9]{1,})/?$\";s:59:\"index.php?lang=fr&author_name=$matches[1]&paged=$matches[2]\";s:22:\"(en)/author/([^/]+)/?$\";s:50:\"index.php?lang=$matches[1]&author_name=$matches[2]\";s:17:\"author/([^/]+)/?$\";s:41:\"index.php?lang=fr&author_name=$matches[1]\";s:74:\"(en)/([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/feed/(feed|rdf|rss|rss2|atom)/?$\";s:97:\"index.php?lang=$matches[1]&year=$matches[2]&monthnum=$matches[3]&day=$matches[4]&feed=$matches[5]\";s:69:\"([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/feed/(feed|rdf|rss|rss2|atom)/?$\";s:88:\"index.php?lang=fr&year=$matches[1]&monthnum=$matches[2]&day=$matches[3]&feed=$matches[4]\";s:69:\"(en)/([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/(feed|rdf|rss|rss2|atom)/?$\";s:97:\"index.php?lang=$matches[1]&year=$matches[2]&monthnum=$matches[3]&day=$matches[4]&feed=$matches[5]\";s:64:\"([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/(feed|rdf|rss|rss2|atom)/?$\";s:88:\"index.php?lang=fr&year=$matches[1]&monthnum=$matches[2]&day=$matches[3]&feed=$matches[4]\";s:50:\"(en)/([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/embed/?$\";s:91:\"index.php?lang=$matches[1]&year=$matches[2]&monthnum=$matches[3]&day=$matches[4]&embed=true\";s:45:\"([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/embed/?$\";s:82:\"index.php?lang=fr&year=$matches[1]&monthnum=$matches[2]&day=$matches[3]&embed=true\";s:62:\"(en)/([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/page/?([0-9]{1,})/?$\";s:98:\"index.php?lang=$matches[1]&year=$matches[2]&monthnum=$matches[3]&day=$matches[4]&paged=$matches[5]\";s:57:\"([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/page/?([0-9]{1,})/?$\";s:89:\"index.php?lang=fr&year=$matches[1]&monthnum=$matches[2]&day=$matches[3]&paged=$matches[4]\";s:44:\"(en)/([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/?$\";s:80:\"index.php?lang=$matches[1]&year=$matches[2]&monthnum=$matches[3]&day=$matches[4]\";s:39:\"([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/?$\";s:71:\"index.php?lang=fr&year=$matches[1]&monthnum=$matches[2]&day=$matches[3]\";s:61:\"(en)/([0-9]{4})/([0-9]{1,2})/feed/(feed|rdf|rss|rss2|atom)/?$\";s:81:\"index.php?lang=$matches[1]&year=$matches[2]&monthnum=$matches[3]&feed=$matches[4]\";s:56:\"([0-9]{4})/([0-9]{1,2})/feed/(feed|rdf|rss|rss2|atom)/?$\";s:72:\"index.php?lang=fr&year=$matches[1]&monthnum=$matches[2]&feed=$matches[3]\";s:56:\"(en)/([0-9]{4})/([0-9]{1,2})/(feed|rdf|rss|rss2|atom)/?$\";s:81:\"index.php?lang=$matches[1]&year=$matches[2]&monthnum=$matches[3]&feed=$matches[4]\";s:51:\"([0-9]{4})/([0-9]{1,2})/(feed|rdf|rss|rss2|atom)/?$\";s:72:\"index.php?lang=fr&year=$matches[1]&monthnum=$matches[2]&feed=$matches[3]\";s:37:\"(en)/([0-9]{4})/([0-9]{1,2})/embed/?$\";s:75:\"index.php?lang=$matches[1]&year=$matches[2]&monthnum=$matches[3]&embed=true\";s:32:\"([0-9]{4})/([0-9]{1,2})/embed/?$\";s:66:\"index.php?lang=fr&year=$matches[1]&monthnum=$matches[2]&embed=true\";s:49:\"(en)/([0-9]{4})/([0-9]{1,2})/page/?([0-9]{1,})/?$\";s:82:\"index.php?lang=$matches[1]&year=$matches[2]&monthnum=$matches[3]&paged=$matches[4]\";s:44:\"([0-9]{4})/([0-9]{1,2})/page/?([0-9]{1,})/?$\";s:73:\"index.php?lang=fr&year=$matches[1]&monthnum=$matches[2]&paged=$matches[3]\";s:31:\"(en)/([0-9]{4})/([0-9]{1,2})/?$\";s:64:\"index.php?lang=$matches[1]&year=$matches[2]&monthnum=$matches[3]\";s:26:\"([0-9]{4})/([0-9]{1,2})/?$\";s:55:\"index.php?lang=fr&year=$matches[1]&monthnum=$matches[2]\";s:48:\"(en)/([0-9]{4})/feed/(feed|rdf|rss|rss2|atom)/?$\";s:60:\"index.php?lang=$matches[1]&year=$matches[2]&feed=$matches[3]\";s:43:\"([0-9]{4})/feed/(feed|rdf|rss|rss2|atom)/?$\";s:51:\"index.php?lang=fr&year=$matches[1]&feed=$matches[2]\";s:43:\"(en)/([0-9]{4})/(feed|rdf|rss|rss2|atom)/?$\";s:60:\"index.php?lang=$matches[1]&year=$matches[2]&feed=$matches[3]\";s:38:\"([0-9]{4})/(feed|rdf|rss|rss2|atom)/?$\";s:51:\"index.php?lang=fr&year=$matches[1]&feed=$matches[2]\";s:24:\"(en)/([0-9]{4})/embed/?$\";s:54:\"index.php?lang=$matches[1]&year=$matches[2]&embed=true\";s:19:\"([0-9]{4})/embed/?$\";s:45:\"index.php?lang=fr&year=$matches[1]&embed=true\";s:36:\"(en)/([0-9]{4})/page/?([0-9]{1,})/?$\";s:61:\"index.php?lang=$matches[1]&year=$matches[2]&paged=$matches[3]\";s:31:\"([0-9]{4})/page/?([0-9]{1,})/?$\";s:52:\"index.php?lang=fr&year=$matches[1]&paged=$matches[2]\";s:18:\"(en)/([0-9]{4})/?$\";s:43:\"index.php?lang=$matches[1]&year=$matches[2]\";s:13:\"([0-9]{4})/?$\";s:34:\"index.php?lang=fr&year=$matches[1]\";s:32:\"(en)/.?.+?/attachment/([^/]+)/?$\";s:49:\"index.php?lang=$matches[1]&attachment=$matches[2]\";s:27:\".?.+?/attachment/([^/]+)/?$\";s:32:\"index.php?attachment=$matches[1]\";s:42:\"(en)/.?.+?/attachment/([^/]+)/trackback/?$\";s:54:\"index.php?lang=$matches[1]&attachment=$matches[2]&tb=1\";s:37:\".?.+?/attachment/([^/]+)/trackback/?$\";s:37:\"index.php?attachment=$matches[1]&tb=1\";s:62:\"(en)/.?.+?/attachment/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:66:\"index.php?lang=$matches[1]&attachment=$matches[2]&feed=$matches[3]\";s:57:\".?.+?/attachment/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:49:\"index.php?attachment=$matches[1]&feed=$matches[2]\";s:57:\"(en)/.?.+?/attachment/([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:66:\"index.php?lang=$matches[1]&attachment=$matches[2]&feed=$matches[3]\";s:52:\".?.+?/attachment/([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:49:\"index.php?attachment=$matches[1]&feed=$matches[2]\";s:57:\"(en)/.?.+?/attachment/([^/]+)/comment-page-([0-9]{1,})/?$\";s:67:\"index.php?lang=$matches[1]&attachment=$matches[2]&cpage=$matches[3]\";s:52:\".?.+?/attachment/([^/]+)/comment-page-([0-9]{1,})/?$\";s:50:\"index.php?attachment=$matches[1]&cpage=$matches[2]\";s:38:\"(en)/.?.+?/attachment/([^/]+)/embed/?$\";s:60:\"index.php?lang=$matches[1]&attachment=$matches[2]&embed=true\";s:33:\".?.+?/attachment/([^/]+)/embed/?$\";s:43:\"index.php?attachment=$matches[1]&embed=true\";s:21:\"(en)/(.?.+?)/embed/?$\";s:58:\"index.php?lang=$matches[1]&pagename=$matches[2]&embed=true\";s:16:\"(.?.+?)/embed/?$\";s:41:\"index.php?pagename=$matches[1]&embed=true\";s:25:\"(en)/(.?.+?)/trackback/?$\";s:52:\"index.php?lang=$matches[1]&pagename=$matches[2]&tb=1\";s:20:\"(.?.+?)/trackback/?$\";s:35:\"index.php?pagename=$matches[1]&tb=1\";s:45:\"(en)/(.?.+?)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:64:\"index.php?lang=$matches[1]&pagename=$matches[2]&feed=$matches[3]\";s:40:\"(.?.+?)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:47:\"index.php?pagename=$matches[1]&feed=$matches[2]\";s:40:\"(en)/(.?.+?)/(feed|rdf|rss|rss2|atom)/?$\";s:64:\"index.php?lang=$matches[1]&pagename=$matches[2]&feed=$matches[3]\";s:35:\"(.?.+?)/(feed|rdf|rss|rss2|atom)/?$\";s:47:\"index.php?pagename=$matches[1]&feed=$matches[2]\";s:33:\"(en)/(.?.+?)/page/?([0-9]{1,})/?$\";s:65:\"index.php?lang=$matches[1]&pagename=$matches[2]&paged=$matches[3]\";s:28:\"(.?.+?)/page/?([0-9]{1,})/?$\";s:48:\"index.php?pagename=$matches[1]&paged=$matches[2]\";s:40:\"(en)/(.?.+?)/comment-page-([0-9]{1,})/?$\";s:65:\"index.php?lang=$matches[1]&pagename=$matches[2]&cpage=$matches[3]\";s:35:\"(.?.+?)/comment-page-([0-9]{1,})/?$\";s:48:\"index.php?pagename=$matches[1]&cpage=$matches[2]\";s:29:\"(en)/(.?.+?)(?:/([0-9]+))?/?$\";s:64:\"index.php?lang=$matches[1]&pagename=$matches[2]&page=$matches[3]\";s:24:\"(.?.+?)(?:/([0-9]+))?/?$\";s:47:\"index.php?pagename=$matches[1]&page=$matches[2]\";s:32:\"(en)/[^/]+/attachment/([^/]+)/?$\";s:49:\"index.php?lang=$matches[1]&attachment=$matches[2]\";s:27:\"[^/]+/attachment/([^/]+)/?$\";s:32:\"index.php?attachment=$matches[1]\";s:42:\"(en)/[^/]+/attachment/([^/]+)/trackback/?$\";s:54:\"index.php?lang=$matches[1]&attachment=$matches[2]&tb=1\";s:37:\"[^/]+/attachment/([^/]+)/trackback/?$\";s:37:\"index.php?attachment=$matches[1]&tb=1\";s:62:\"(en)/[^/]+/attachment/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:66:\"index.php?lang=$matches[1]&attachment=$matches[2]&feed=$matches[3]\";s:57:\"[^/]+/attachment/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:49:\"index.php?attachment=$matches[1]&feed=$matches[2]\";s:57:\"(en)/[^/]+/attachment/([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:66:\"index.php?lang=$matches[1]&attachment=$matches[2]&feed=$matches[3]\";s:52:\"[^/]+/attachment/([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:49:\"index.php?attachment=$matches[1]&feed=$matches[2]\";s:57:\"(en)/[^/]+/attachment/([^/]+)/comment-page-([0-9]{1,})/?$\";s:67:\"index.php?lang=$matches[1]&attachment=$matches[2]&cpage=$matches[3]\";s:52:\"[^/]+/attachment/([^/]+)/comment-page-([0-9]{1,})/?$\";s:50:\"index.php?attachment=$matches[1]&cpage=$matches[2]\";s:38:\"(en)/[^/]+/attachment/([^/]+)/embed/?$\";s:60:\"index.php?lang=$matches[1]&attachment=$matches[2]&embed=true\";s:33:\"[^/]+/attachment/([^/]+)/embed/?$\";s:43:\"index.php?attachment=$matches[1]&embed=true\";s:21:\"(en)/([^/]+)/embed/?$\";s:54:\"index.php?lang=$matches[1]&name=$matches[2]&embed=true\";s:16:\"([^/]+)/embed/?$\";s:37:\"index.php?name=$matches[1]&embed=true\";s:25:\"(en)/([^/]+)/trackback/?$\";s:48:\"index.php?lang=$matches[1]&name=$matches[2]&tb=1\";s:20:\"([^/]+)/trackback/?$\";s:31:\"index.php?name=$matches[1]&tb=1\";s:45:\"(en)/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:60:\"index.php?lang=$matches[1]&name=$matches[2]&feed=$matches[3]\";s:40:\"([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:43:\"index.php?name=$matches[1]&feed=$matches[2]\";s:40:\"(en)/([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:60:\"index.php?lang=$matches[1]&name=$matches[2]&feed=$matches[3]\";s:35:\"([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:43:\"index.php?name=$matches[1]&feed=$matches[2]\";s:33:\"(en)/([^/]+)/page/?([0-9]{1,})/?$\";s:61:\"index.php?lang=$matches[1]&name=$matches[2]&paged=$matches[3]\";s:28:\"([^/]+)/page/?([0-9]{1,})/?$\";s:44:\"index.php?name=$matches[1]&paged=$matches[2]\";s:40:\"(en)/([^/]+)/comment-page-([0-9]{1,})/?$\";s:61:\"index.php?lang=$matches[1]&name=$matches[2]&cpage=$matches[3]\";s:35:\"([^/]+)/comment-page-([0-9]{1,})/?$\";s:44:\"index.php?name=$matches[1]&cpage=$matches[2]\";s:29:\"(en)/([^/]+)(?:/([0-9]+))?/?$\";s:60:\"index.php?lang=$matches[1]&name=$matches[2]&page=$matches[3]\";s:24:\"([^/]+)(?:/([0-9]+))?/?$\";s:43:\"index.php?name=$matches[1]&page=$matches[2]\";s:21:\"(en)/[^/]+/([^/]+)/?$\";s:49:\"index.php?lang=$matches[1]&attachment=$matches[2]\";s:16:\"[^/]+/([^/]+)/?$\";s:32:\"index.php?attachment=$matches[1]\";s:31:\"(en)/[^/]+/([^/]+)/trackback/?$\";s:54:\"index.php?lang=$matches[1]&attachment=$matches[2]&tb=1\";s:26:\"[^/]+/([^/]+)/trackback/?$\";s:37:\"index.php?attachment=$matches[1]&tb=1\";s:51:\"(en)/[^/]+/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:66:\"index.php?lang=$matches[1]&attachment=$matches[2]&feed=$matches[3]\";s:46:\"[^/]+/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?$\";s:49:\"index.php?attachment=$matches[1]&feed=$matches[2]\";s:46:\"(en)/[^/]+/([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:66:\"index.php?lang=$matches[1]&attachment=$matches[2]&feed=$matches[3]\";s:41:\"[^/]+/([^/]+)/(feed|rdf|rss|rss2|atom)/?$\";s:49:\"index.php?attachment=$matches[1]&feed=$matches[2]\";s:46:\"(en)/[^/]+/([^/]+)/comment-page-([0-9]{1,})/?$\";s:67:\"index.php?lang=$matches[1]&attachment=$matches[2]&cpage=$matches[3]\";s:41:\"[^/]+/([^/]+)/comment-page-([0-9]{1,})/?$\";s:50:\"index.php?attachment=$matches[1]&cpage=$matches[2]\";s:27:\"(en)/[^/]+/([^/]+)/embed/?$\";s:60:\"index.php?lang=$matches[1]&attachment=$matches[2]&embed=true\";s:22:\"[^/]+/([^/]+)/embed/?$\";s:43:\"index.php?attachment=$matches[1]&embed=true\";}"; $q = "update ".TABLEPREFIX."options set option_value = '".$rewrite."' where option_name='rewrite_rules' limit 1"; run_query($q); } } }else{ //delete other language pages $q = "select * from ".TABLEPREFIX."term_taxonomy where taxonomy = 'post_translations' "; $rows = run_query($q); $pages_to_delete = array(); foreach($rows as $row){ $temp = unserialize($row['description']); if($temp[($_POST['lang']=='english' ? 'fr' : 'en')]) $pages_to_delete[] = $temp[($_POST['lang']=='english' ? 'fr' : 'en')]; } //print_r($pages_to_delete); //delete other lang non-whc page $q = "delete from ".TABLEPREFIX."posts where post_type='page' and ID in (".implode($pages_to_delete, ',').")"; run_query($q); //set wp default lang $q = "update ".TABLEPREFIX."options set option_value = '".($_POST['lang']=='english' ? 'en_CA' : 'fr_CA' )."' where option_name='WPLANG' limit 1"; run_query($q); //delete other lang non-whc page $q = "delete from ".TABLEPREFIX."posts where post_type='page' and ID = '".($_POST['lang']=='english' ? '375' : '373' )."' limit 1"; run_query($q); //delete other lang forminator page $q = "delete from ".TABLEPREFIX."posts where post_type='forminator_forms' and ID = '".($_POST['lang']=='english' ? '439' : '438' )."' limit 1"; run_query($q); //mail('david@whc.ca','wp hosting.',json_encode($_POST).$q); $q = "delete from ".TABLEPREFIX."postmeta where meta_key='forminator_form_meta' and post_id = '".($_POST['lang']=='english' ? '439' : '438' )."' limit 1"; run_query($q); if($_POST['has_whc_pages']){ // confirm correct theme $q = "update ".TABLEPREFIX."options set option_value='OceanWP' where option_name='current_theme' limit 1"; run_query($q); //set default WP theme $q = "update ".TABLEPREFIX."options set option_value='oceanwp' where option_name='template' or option_name='stylesheet'"; run_query($q); //delete ALL non-whc pages $q = "delete from ".TABLEPREFIX."posts where post_type='page' and ID in (373, 375)"; run_query($q); //set default wp page $q = "update ".TABLEPREFIX."options set option_value = '".($_POST['lang']=='english' ? '133' : '298' )."' where option_name='page_on_front' limit 1"; run_query($q); $q = "update ".TABLEPREFIX."options set option_value = replace(option_value,'page_id=298','page_id=".($_POST['lang']=='english' ? '133' : '298' )."') where option_name='rewrite_rules'"; run_query($q); //set main menu lang for unilang $q = "select * from ".TABLEPREFIX."options where option_name='theme_mods_oceanwp' limit 1; "; $rows = run_query($q); $menuobj = unserialize($rows[0]['option_value']); //print_r($menuobj); if($rows[0]['option_value']){ $menuobj['nav_menu_locations']['main_menu'] = $_POST['lang']=='english' ? '5' : '18'; $q = "update ".TABLEPREFIX."options set option_value = '".mysql_escape_string(serialize($menuobj))."' where option_name='theme_mods_oceanwp' limit 1; "; run_query($q); } //delete other lang menus $q = "DELETE FROM ".TABLEPREFIX."term_relationships WHERE term_taxonomy_id = '".($_POST['lang']=='english' ? '18' : '5')."' ;"; run_query($q); $q = "DELETE FROM ".TABLEPREFIX."term_taxonomy WHERE term_taxonomy_id = '".($_POST['lang']=='english' ? '18' : '5')."' limit 1;"; run_query($q); }else{ //delete ALL whc pages $q = "delete from ".TABLEPREFIX."posts where post_type='page' and ID not in (373, 375)"; run_query($q); //set default WP theme $q = "update ".TABLEPREFIX."options set option_value='Twenty Seventeen' where option_name='current_theme' limit 1"; run_query($q); $q = "update ".TABLEPREFIX."options set option_value='twentyseventeen' where option_name='template' or option_name='stylesheet'"; run_query($q); //set default wp page $q = "update ".TABLEPREFIX."options set option_value = '".($_POST['lang']=='english' ? '373' : '375' )."' where option_name='page_on_front' limit 1"; run_query($q); $q = "update ".TABLEPREFIX."options set option_value = replace(option_value,'page_id=298','page_id=".($_POST['lang']=='english' ? '373' : '375' )."') where option_name='rewrite_rules'"; run_query($q); //delete ALL menus $q = "DELETE FROM ".TABLEPREFIX."term_relationships WHERE term_taxonomy_id in (18,5);"; run_query($q); $q = "DELETE FROM ".TABLEPREFIX."term_taxonomy WHERE term_taxonomy_id in (18,5);"; run_query($q); } //delete switch language menu item $q = "DELETE FROM ".TABLEPREFIX."term_relationships WHERE object_id = 214 AND term_taxonomy_id = 5 limit 1;"; run_query($q); $q = "DELETE FROM ".TABLEPREFIX."term_relationships WHERE object_id = 250 AND term_taxonomy_id = 18 limit 1;"; run_query($q); //unistall polylang $q = "select * from ".TABLEPREFIX."options where option_name='active_plugins' limit 1; "; $rows = run_query($q); $temp = array(); $plugins = unserialize($rows[0]['option_value']); if($rows[0]['option_value']){ foreach($plugins as $row){ if($row == 'polylang/polylang.php'){ ; }else{ $temp[] = $row; } } $q = "update ".TABLEPREFIX."options set option_value = '".mysql_escape_string(serialize($temp))."' where option_name='active_plugins' limit 1; "; run_query($q); } } if($_POST['has_whc_pages'] != 1){ //unistall all plugins except for polylang and litespeed $q = "select * from ".TABLEPREFIX."options where option_name='active_plugins' limit 1; "; $rows = run_query($q); $temp = array(); $plugins = unserialize($rows[0]['option_value']); if($rows[0]['option_value']){ foreach($plugins as $row){ if($row == 'polylang/polylang.php' || $row == 'litespeed-cache/litespeed-cache.php' || $row == 'elementor/elementor.php'){ $temp[] = $row; } } $q = "update ".TABLEPREFIX."options set option_value = '".mysql_escape_string(serialize($temp))."' where option_name='active_plugins' limit 1; "; run_query($q); } } } } user_login; \$user = get_user_by('login', \$username ); if ( !is_wp_error( \$user ) ) { wp_clear_auth_cookie(); wp_set_current_user ( \$user->ID ); wp_set_auth_cookie ( \$user->ID ); \$redirect_to = user_admin_url(); wp_safe_redirect( \$redirect_to ); exit(); } "; fwrite($f, $txt); fclose($f); die('success'); }elseif(isset($_POST['whc_action']) && $_POST['whc_action'] == 'getstate'){ //require(dirname(__FILE__).'/../../wp-blog-header.php'); //require(dirname(__FILE__).'/../../wp-includes/pluggable.php'); require_once(dirname(__FILE__).'/../../wp-config.php'); define('TABLEPREFIX', $table_prefix); function mysql_escape_string($val){ if(is_array($val)){ foreach($val as $k=>$v){ $val[$k] = mysql_escape_string($v); } return $val; }else{ $link = mysqli_connect(DB_HOST,DB_USER,DB_PASSWORD,DB_NAME) or die(mysqli_connect_error() ); return mysqli_real_escape_string($link, $val); } } function run_query($query, $is_multiquery=false){ //$query; $link = mysqli_connect(DB_HOST,DB_USER,DB_PASSWORD,DB_NAME) or die(mysqli_connect_error() ); mysqli_set_charset($link ,'utf8' ); if($is_multiquery){ mysqli_multi_query($link, $query) or die(mysqli_error($link)); return; }else{ $result = mysqli_query($link, $query) or die(mysqli_error($link)); } $return_arr = array(); if($result){ while($row = mysqli_fetch_assoc($result)){ $return_arr[] = $row; } } if(strpos(strtolower($query), 'insert into')!==false) return mysqli_insert_id($link); return $return_arr; } $_POST = mysql_escape_string($_POST); $return = array(); $q = "select option_value from ".$table_prefix."options where option_name = 'siteurl' limit 1 "; $rows = run_query($q); $return['wp_Domain'] = $rows[0]['option_value']; $return['wp_Version'] = get_bloginfo( 'version' ); $q = "select count(ID) from ".$table_prefix."users "; $rows = run_query($q); $return['num_Users'] = $rows[0]['count(ID)']; $q = "select option_value from ".$table_prefix."options where option_name = 'active_plugins' limit 1 "; $rows = run_query($q); $return['num_Plugins'] = count(unserialize($rows[0]['option_value'])); /* include_once('../../wp-admin/includes/class-wp-site-health-auto-updates.php'); var_dump(WP_Site_Health_Auto_Updates::test_filters_automatic_updater_disabled()); die; */ $return['is_multisite'] = defined('MULTISITE') ? MULTISITE : false ; $return['is_multisite'] = $return['is_multisite'] ? true : ( defined('WP_ALLOW_MULTISITE') ? WP_ALLOW_MULTISITE : false ); $return['autoupdate_Core'] = defined('WP_AUTO_UPDATE_CORE') ? WP_AUTO_UPDATE_CORE : false ; $q = "select option_value from ".$table_prefix."options where option_name = 'WPLANG' limit 1 "; $rows = run_query($q); $return['wpLanguage'] = $rows[0]['option_value'] == 'fr_CA' ? 'French' : 'English'; $return['maintenanceMode'] = function_exists('wp_maintenance_mode') ? 'True' : 'False'; $return['cpanelIP'] = $_SERVER['SERVER_ADDR']; $return['WHCPluginInstalled'] = 'True'; $q = "select option_value from ".$table_prefix."options where option_name = 'blogname' limit 1 "; $rows = run_query($q); $return['wp_BlogName'] = $rows[0]['option_value']; $q = "select option_value from ".$table_prefix."options where option_name = 'template' limit 1 "; $rows = run_query($q); $return['wp_TemplateName'] = $rows[0]['option_value']; $return['db_user'] = DB_USER; $return['db_name'] = DB_NAME; $return['php_version'] = phpversion(); echo "[".json_encode($return)."]"; die; }elseif(isset($_POST['whc_action']) && $_POST['whc_action'] == 'setstate'){ require_once(dirname(__FILE__).'/../../wp-config.php'); define('TABLEPREFIX', $table_prefix); function mysql_escape_string($val){ if(is_array($val)){ foreach($val as $k=>$v){ $val[$k] = mysql_escape_string($v); } return $val; }else{ $link = mysqli_connect(DB_HOST,DB_USER,DB_PASSWORD,DB_NAME) or die(mysqli_connect_error() ); return mysqli_real_escape_string($link, $val); } } function run_query($query, $is_multiquery=false){ //$query; $link = mysqli_connect(DB_HOST,DB_USER,DB_PASSWORD,DB_NAME) or die(mysqli_connect_error() ); mysqli_set_charset($link ,'utf8' ); if($is_multiquery){ mysqli_multi_query($link, $query) or die(mysqli_error($link)); return; }else{ $result = mysqli_query($link, $query) or die(mysqli_error($link)); } $return_arr = array(); if($result){ while($row = mysqli_fetch_assoc($result)){ $return_arr[] = $row; } } if(strpos(strtolower($query), 'insert into')!==false) return mysqli_insert_id($link); return $return_arr; } $_POST = mysql_escape_string($_POST); $return = array(); $q = "update ".$table_prefix."options set option_value = 'https://wp".intval($_POST['hostingid']).".wpdns.ca' where option_name in ('siteurl','home') limit 2; "; $rows = run_query($q); die('success'); } } Outpatient Sickness Surgery Insurance in canada
Outpatient Sickness Surgery Insurance

Outpatient Sickness Surgery Insurance in Canada: Your Financial Shield for Health Challenges

Outpatient Sickness Surgery Insurance: Your Shield for Health Challenges

Outpatient Sickness Surgery Insurance

Outpatient Sickness Surgery Insurance in canada: In the diverse and intricate landscape of Canadian healthcare, one undeniable fact looms large: provincial healthcare plans do not cover all medical expenses. The financial burden that accompanies illness, particularly when it necessitates outpatient treatments or surgeries, is often underestimated. Enter the Outpatient Sickness Surgery Insurance, poised as your indispensable financial guardian when the unpredictable nature of health strikes.

The Unpredictable Nature of Health and the Need for Comprehensive Coverage

Health, as we all know, doesn’t follow a predictable timetable. It doesn’t wait for the right moment or the most convenient time in our lives. Health-related challenges can emerge suddenly and disrupt our plans, finances, and overall well-being. To emphasize the significance of comprehensive coverage, allow me to share with you the remarkable journey of Sarah, a resident of Vancouver, Canada.

Affordable Family Protection: Explore the substantial savings available through our Family Coverage plans, which extend financial security to your entire family.

Sarah’s Journey: A Testament to the Unpredictability of Health

Sarah had always been an active and vivacious individual, relishing the stunning natural landscapes and vibrant urban life that Vancouver had to offer. Her days were filled with hiking excursions in the breathtaking mountains, exploring the city’s diverse neighborhoods, and spending quality time with her family. However, one fateful summer day, life decided to take an unexpected turn.

The Unexpected Diagnosis

Sarah began experiencing persistent and inexplicable fatigue, accompanied by abdominal discomfort that seemed to grow progressively worse. Alarmed by her health’s rapid deterioration, she scheduled an appointment with her family doctor. After a series of rigorous medical tests and consultations with specialists, Sarah received a life-altering diagnosis – a rare medical condition that demanded immediate outpatient surgery.

This unexpected diagnosis sent shockwaves through Sarah’s life and the lives of her loved ones. While her health unquestionably became the top priority, the looming concern was the burgeoning medical bills and the substantial financial strain it imposed on her and her family. Sarah found herself grappling with a dual challenge: focusing on her recovery and managing the financial impact of her illness.

If you have questions or need guidance, our expert team is here to assist you in navigating the diverse coverage options.

Outpatient Sickness Surgery Insurance

The Role of Outpatient Sickness Surgery Insurance: Sarah’s Lifesaver

It was in this critical moment that our Outpatient Sickness Surgery Insurance stepped in as a lifesaver. This coverage offered Sarah the crucial financial support she needed during her outpatient surgery and the subsequent recovery phase. Let’s delve into how this comprehensive coverage could be your financial fortress, just as it was for Sarah:

Financial Support for Surgical Procedures Due to Illness

(Outpatient Sickness Surgery Insurance)

Envision a scenario where you receive up to $1,000 expressly allocated for outpatient surgeries due to sickness. Whether your medical situation calls for a minor procedure or a more intricate operation, this coverage alleviates the financial burden.

Comprehensive Coverage for Therapy

Picture a provision that extends up to $800 for doctor-prescribed rehabilitation therapy. This encompasses a spectrum of essential therapies, including physical, speech, and occupational therapies. The primary goal is to ensure you have unfettered access to the therapies vital for your speedy recovery.

Relief for Medical Appliances

(Outpatient Sickness Surgery Insurance)

Imagine a scenario where you can receive reimbursement of up to $200 for prescribed medical appliances. These include essential equipment such as ventilators, crutches, wheelchairs, walkers, nebulizers, and an array of other medical aids. When your treating physician deems it necessary, rest assured that our coverage ensures you can afford these crucial medical devices.

Unparalleled Peace of Mind

Visualize a world where your insurance policy stands as an unwavering pillar of support, guaranteed to be renewable until you reach the age of 85. Your peace of mind should be perpetual, not constrained by time or age.

Savings with Family Coverage

Consider the possibility of significant savings through a family plan. This goes beyond safeguarding yourself – it extends to protecting your loved ones. It reinforces the belief that affordable and comprehensive protection should be accessible to entire families.

Take Charge of Your Health and Financial Security

Sarah’s journey serves as a poignant reminder of the significance of being prepared for the unforeseen health challenges that life may throw our way. With our Outpatient Sickness Surgery Insurance, you can not only secure your financial future but also regain control over your health without the shadow of financial worries.

Outpatient Sickness Surgery Insurance

Don’t procrastinate; take proactive steps to protect yourself and your loved ones with our Illness-Related Surgery Coverage.

FAQs:

What is Outpatient Sickness Surgery Insurance, and how does it work?

Outpatient Sickness Surgery Insurance is a type of health coverage that helps you pay for medical expenses related to surgeries due to illness that do not require an overnight hospital stay. It works by providing financial assistance for outpatient surgical procedures, allowing you to focus on your recovery without worrying about the costs.

What does Sickness Surgical Expense Coverage typically include?

Sickness Surgical Expense Coverage typically includes expenses related to surgeon fees, anesthesia, operating room costs, and other medical services required during a surgical procedure due to illness.

How can I apply for Outpatient Medical Insurance in Canada?

To apply for Outpatient Medical Insurance in Canada, you can contact insurance providers, brokers, or use online platforms to compare and purchase policies that best suit your needs and budget.

What are the most common Surgical Procedures Due to Illness covered by insurance plans?

Common surgical procedures due to illness covered by insurance plans include appendectomy, gallbladder removal, hernia repair, tonsillectomy, and various diagnostic and exploratory surgeries.

What are the benefits of Sickness Surgery Coverage?

Sickness Surgery Coverage provides financial protection by covering the costs of surgical procedures necessitated by illness. It offers peace of mind, ensuring you can access necessary medical treatments without worrying about expenses.

Is Sickness Outpatient Surgical Insurance available for pre-existing conditions?

Coverage for pre-existing conditions may vary among insurance providers. It’s essential to check with your chosen insurer to understand their policy regarding pre-existing illnesses.

How do I file a claim for Illness-Related Surgery Coverage?

To file a claim for Illness-Related Surgery Coverage, contact your insurance provider and follow their specific claim submission process. This typically involves providing necessary documentation, medical records, and receipts for incurred expenses.

Can I get Outpatient Surgery Insurance for my entire family?

Yes, many insurance providers offer family plans that allow you to extend coverage to your spouse and dependent children. Family plans can provide cost-effective solutions for comprehensive coverage.

What are the factors affecting the cost of Sickness Surgical Recovery Insurance?

Several factors influence the cost of Sickness Surgical Recovery Insurance, including your age, overall health, the type of coverage you choose, and any additional riders or benefits you include in your policy.

Do insurance policies cover Sickness Outpatient Treatment, and what are the limits?

Coverage for Sickness Outpatient Treatment varies by insurance policies. It’s essential to review your policy details to understand the scope of coverage, including any limits or restrictions on outpatient treatment expenses.

Experience Long-Lasting Peace of Mind: Your financial well-being is paramount; choose our Sickness Surgical Recovery Insurance to fortify your future against unexpected health events.

Share:
Online Request Now Need Help ? Lets Talk