query("SELECT catid,w_id,e_id,weblog,title FROM entires WHERE how='2' and date <= '$futuredate'"); if($db->num_rows($checkfuture)>0){ while($r=$db->get_row($checkfuture)) { $catid=$r["catid"]; $w_id=$r["w_id"]; $e_id=$r["e_id"]; $weblog=$r["weblog"]; $title=$r["title"]; if($catid != ""){ $base_skin = explode( ',', "$catid"); foreach ($base_skin as $value) { $db->query("UPDATE Category SET countpost=countpost + 1 WHERE w_id = '$w_id' and c_id= '$value'"); } //for foreach } //for ife khali } $db->query("UPDATE entires SET how='1' WHERE how='2' and date <= '$futuredate'"); } $db->free($checkfuture); $result45 = $db->query("SELECT * FROM fullads where active='1'"); if($db->num_rows($result45)>0){ while($r=$db->get_row($result45)) { $weblog=$r["weblog"]; $timehost=$r["timehost"]; $date=$r["date"]; $date1=date('y-m-d'); if($date != "$date1"){ $db->query("UPDATE fullads SET date='$date1' WHERE weblog='$weblog' and active='1'"); $db->query("UPDATE fullads SET timehost=$timehost-1 WHERE weblog='$weblog' and active='1'"); } } } $db->free($result45); $result450 = $db->query("SELECT timehost FROM fullads WHERE timehost='0'"); if($db->num_rows($result450)>0){ $sql ="DELETE FROM fullads WHERE timehost='0'"; $result = $db->query($sql); } $db->free($result450); //ta inja 0.31693 if($domain=="blogveb.com" or $domain=="blogweb.ir" or $domain=="blogveb.ir"){ include('main.php'); } else { include('Function.php'); include('class/jdf.php'); if(isset($_GET['blog'])){ $weblog=$_GET['blog']; } else { //for get blog $checkweblog = $db->query("SELECT domain FROM Domains WHERE domain='$domain'"); if($db->num_rows($checkweblog)>0){ //find blog name $searchblogname =$db->super_query("SELECT weblog FROM Domains where domain = '$domain'"); $weblog=$searchblogname["weblog"]; } else { $weblog=''; } //end for get domain } //end for get blog & domain // check block site $checkblocked = $db->query("SELECT * FROM blocksite WHERE act='1'"); if($db->num_rows($checkblocked)>0) { include('Blocksite.php'); } else { //check blog $checkblog = $db->query("SELECT * FROM Users where txtweblog = '$weblog'"); if($db->num_rows($checkblog)==0) { include('Available.php'); } else { $adresssss=$domain.$_SERVER['REQUEST_URI']; //checkabuse site $checkabuse = $db->query("SELECT blogname FROM abuseadress WHERE blogname='$adresssss'"); if($db->num_rows($checkabuse)>0) { include('Blockadress.php'); } else { //checkabuse site $checkabuse2 = $db->query("SELECT blogname FROM abuseblog WHERE blogname='$weblog'"); if($db->num_rows($checkabuse2)>0) { include('Block.php'); } else { //check available ip if (!empty($_SERVER['HTTP_CLIENT_IP'])) //check ip from share internet { @$ip= htmlspecialchars($_SERVER['HTTP_CLIENT_IP']); @$ip= addslashes($ip); } elseif (!empty($_SERVER['HTTP_X_FORWARDED_FOR'])) //to check ip is pass from proxy { @$ip= htmlspecialchars($_SERVER['HTTP_X_FORWARDED_FOR']); @$ip= addslashes($ip); } else { @$ip= htmlspecialchars($_SERVER['REMOTE_ADDR']); @$ip= addslashes($ip); } $checkip = $db->query("SELECT * FROM ip WHERE ip='$ip' and weblog='$weblog'"); if($db->num_rows($checkip)>0) { include('Blockip.php'); } else { //finish //result blog template and information $result12 = $db->query("SELECT * FROM Users where txtweblog = '$weblog' and how='0'"); while($r=$db->get_row($result12)) { $result4 = $db->query("SELECT catid FROM entires where weblog = '$weblog'"); while($b=$db->get_row($result4)) { $catid=$b['catid']; $base_skin = explode ( ',', "$catid"); foreach ($base_skin as $value) { $db->query("UPDATE Category SET countpost=countpost + 1 WHERE weblog = '$weblog' and c_id= '$value'"); } } $db->free($result4); $db->query("UPDATE Users SET how='1' WHERE txtweblog = '$weblog'"); } $db->free($result12); //finish find $result123 = $db->query("SELECT * FROM Users where txtweblog = '$weblog' and how2='0'"); while($r=$db->get_row($result123)) { $result44 = $db->query("SELECT author FROM entires where weblog = '$weblog'"); while($b=$db->get_row($result44)) { $author=$b['author']; $db->query("UPDATE Authors SET CountPost=CountPost + 1 WHERE weblog = '$weblog' and Author= '$author'"); } $db->free($result44); $db->query("UPDATE Users SET how2='1' WHERE txtweblog = '$weblog'"); } $db->free($result123); //finish find //author to id $result44 = $db->query("SELECT a_id,Author FROM Authors where weblog = '$weblog' and how3='0'"); while($b=$db->get_row($result44)) { $a_id=$b['a_id']; $Author=$b['Author']; $db->query("UPDATE entires SET author='$a_id' WHERE weblog = '$weblog' and author= '$Author'"); $db->query("UPDATE Authors SET how3='1' WHERE weblog = '$weblog'"); } $db->free($result44); //finish find //author //az inja //result blog template and information $s1=md5('memberid'.date("Ymd").'-'.$weblog); $s2=md5('username'.date("Ymd").'-'.$weblog); $resulttemplate = $db->super_query("SELECT template,how5,how6,linkbox,news,signuptemplate,mobliletemplate,contacttemplate,commenttemplate,w_id,txttitle,txtdescription,txtpostInpage,cmbPostDateFormat,cmbPostTimeFormat,BlogAbout,image,BlogEmailEnable,txtItem,txtemail,lastforum,logo,signupact FROM Users where txtweblog = '$weblog'"); $linkbox=$resulttemplate["linkbox"]; $news=$resulttemplate["news"]; $template=$resulttemplate["template"]; $signuptemplate=$resulttemplate["signuptemplate"]; $mobliletemplate=$resulttemplate["mobliletemplate"]; $contacttemplate=$resulttemplate["contacttemplate"]; $commenttemplate=$resulttemplate["commenttemplate"]; $w_id=$resulttemplate["w_id"]; $txttitle=$resulttemplate["txttitle"]; $txtdescription=$resulttemplate["txtdescription"]; $txtpostInpage=$resulttemplate["txtpostInpage"]; $cmbPostDateFormat=$resulttemplate["cmbPostDateFormat"]; $cmbPostTimeFormat=$resulttemplate["cmbPostTimeFormat"]; $BlogAbout=$resulttemplate["BlogAbout"]; $image=$resulttemplate["image"]; $BlogEmailEnable=$resulttemplate["BlogEmailEnable"]; $txtItem=$resulttemplate["txtItem"]; $txtemail=$resulttemplate["txtemail"]; $lastforum=$resulttemplate["lastforum"]; $logo=$resulttemplate["logo"]; $signupact=$resulttemplate["signupact"]; $how5=$resulttemplate["how5"]; $how6=$resulttemplate["how6"]; $search_array5 = Array("<", ">", "\"","'","&"); $replace_array5 = Array("<", ">", ""","'","&"); $template = str_replace($replace_array5,$search_array5, $template); $linkbox= str_replace($replace_array5,$search_array5, $linkbox); $news= str_replace($replace_array5,$search_array5, $news); $signuptemplate= str_replace($replace_array5,$search_array5, $signuptemplate); $commenttemplate= str_replace($replace_array5,$search_array5, $commenttemplate); $mobliletemplate= str_replace($replace_array5,$search_array5, $mobliletemplate); $contacttemplate= str_replace($replace_array5,$search_array5, $contacttemplate); if($how5=="0"){ $result343 = $db->query("SELECT * FROM forumtemplate where t_id = '1'"); while($r=$db->get_row($result343)) { $t_id=$r["t_id"]; $hometemp=$r["hometemp"]; $moretemp=$r["moretemp"]; $cattemp=$r["cattemp"]; } $db->free($result343); $db->query("UPDATE Users SET indexforum='$hometemp' WHERE w_id='$w_id'"); $db->query("UPDATE Users SET moreforum='$moretemp' WHERE w_id='$w_id'"); $db->query("UPDATE Users SET forumcattemplate='$cattemp' WHERE w_id='$w_id'"); $db->query("UPDATE Users SET how5='1' WHERE w_id='$w_id'"); } if($logo==""){ $template=str_replace("","",$template); $template=str_replace("","",$template); } else { $logos=between("", "", $template); $template = str_replace("".$logos."", "$logo", $template); } if($lastforum=="0"){ $BlogLastForum=between("", "", $template); $template = str_replace("".$BlogLastForum."", "", $template); } //finish find //ta inja 0.177296 //archive $result123 = $db->query("SELECT * FROM Users where txtweblog = '$weblog' and how3='0'"); if($db->num_rows($result123)>0) { while($r=$db->get_row($result123)) { $eu = $db->query("SELECT DATE_FORMAT(date,'%M-%Y') AS m_date FROM entires Where weblog = '$weblog' and how = '1' GROUP BY m_date ORDER BY date desc"); if($db->num_rows($eu)>0){ while($row = $db->get_object($eu)) { $time = strtotime($row->m_date); $month1 = jgmdate("m",$time); $year1 = jgmdate("Y",$time); $result1287 = $db->query("SELECT w_id FROM montharchive where weblog= '$weblog' and year='$year1' and month='$month1'"); if($db->num_rows($result1287)=="0") { $db->query("INSERT INTO montharchive (w_id,year,month,weblog)VALUES('$w_id','$year1','$month1','$weblog')"); } $db->free($result1287); $db->query("UPDATE Users SET how3='1' WHERE txtweblog = '$weblog'"); } } $db->free($eu); } } $db->free($result123); //archive //weblog to forum $checkforum =$db->super_query("SELECT COUNT(*) as count FROM thread WHERE weblog = '$weblog'"); if($checkforum['count']>0){ $partnameforum =$db->super_query("SELECT COUNT(*) as count FROM partnameforum WHERE weblog = '$weblog' and name='عمومی'"); if($partnameforum['count']=="0"){ $datete='2011-03-20 23:18:25'; $db->query("INSERT INTO partnameforum (w_id,name,date,weblog)VALUES('$w_id','عمومی','$datete','$weblog')"); } $partnameforum1 =$db->super_query("SELECT p_id FROM partnameforum WHERE weblog = '$weblog' and name='عمومی'"); $partname=$partnameforum1['p_id']; $forums =$db->super_query("SELECT COUNT(*) as count FROM forums WHERE weblog = '$weblog' and name='عمومی'"); if($forums['count']=="0"){ $datete='2011-03-20 23:18:25'; $db->query("INSERT INTO forums (w_id,name,partid,manager,descs,date,weblog)VALUES('$w_id','عمومی','$partname','','مطالب انجمن قبلی در اینجا وارد شده است','$datete','$weblog')"); } $partnameforum1 =$db->super_query("SELECT f_id FROM forums WHERE weblog = '$weblog' and name='عمومی'"); $talarid=$partnameforum1['f_id']; $result4 = $db->query("SELECT * FROM thread where weblog = '$weblog'"); while($b=$db->get_row($result4)) { $t_id=$b['t_id']; $title=$b['title']; $author=$b['author']; $search = array("\n", "&", """, "'", "\", """, "'", "<", ">"); $replace = array("\r\n", "&", "\"", "'", "\\", '\"', "\'", "<", ">"); $title= str_replace($replace, $search, $title); $partnameforum17 =$db->super_query("SELECT COUNT(*) as count FROM members WHERE weblog = '$weblog' and username='$author'"); if($partnameforum17['count']=="0"){ $partnameforum1 =$db->super_query("SELECT m_id FROM members WHERE weblog = '$weblog' and username='admin'"); $m_id=$partnameforum1['m_id']; } else { $partnameforum1 =$db->super_query("SELECT m_id FROM members WHERE weblog = '$weblog' and username='$author'"); $m_id=$partnameforum1['m_id']; } $datete='2011-03-20 23:18:25'; $db->query("INSERT INTO newthread(weblog,author_id,talarid,important,how,w_id,title,count,date)VALUES('$weblog','$m_id','$talarid','0','0','$w_id','$title','0','$datete')"); $result81 = $db->query("SELECT answer FROM answerthread where weblog = '$weblog' and t_id='$t_id' order by t_id desc"); while($b=$db->get_row($result81)){ $content=$b['answer']; $search = array("\n", "&", """, "'", "\", """, "'", "<", ">"); $replace = array("\r\n", "&", "\"", "'", "\\", '\"', "\'", "<", ">"); $content= str_replace($replace, $search, $content); $result1 = $db->query("SELECT * FROM newthread where weblog = '$weblog' and title='$title' and author_id='$m_id' and talarid='$talarid' order by t_id desc LIMIT 0,1"); while($r=$db->get_row($result1)) { $t_id1=$r["t_id"]; $datete='2011-03-20 23:18:25'; $db->query("INSERT INTO newanswerthread (weblog,author_id,date,w_id,answer,t_id)VALUES('$weblog','$m_id','$datete','$w_id','$content','$t_id1')"); } } } } $sql = "DELETE FROM thread WHERE weblog = '$weblog'"; $result = $db->query($sql); $sql2 = "DELETE FROM answerthread where weblog = '$weblog'"; $result2 = $db->query($sql2); //end if($how6=="0"){ $result816 = $db->query("SELECT title FROM newthread where weblog = '$weblog' order by t_id desc limit 0,200"); while($b=$db->get_row($result816)){ $title=$b['title']; $checkforum1q =$db->super_query("SELECT COUNT(*) as count FROM newthread WHERE title='$title' and weblog = '$weblog'"); $checkforumcounttitle=$checkforum1q['count']; if($checkforumcounttitle > 1){ $checkforumcount2=$checkforumcounttitle - 1; $result8155 = $db->query("SELECT t_id FROM newthread where weblog = '$weblog' and title='$title' order by t_id desc limit 0,$checkforumcount2"); while($d=$db->get_row($result8155)){ $aid=$d['t_id']; $sql233 = "DELETE FROM newthread where weblog = '$weblog' and t_id='$aid'"; $result233 = $db->query($sql233); } } } $result816 = $db->query("SELECT answer FROM newanswerthread where weblog = '$weblog' order by a_id desc"); while($b=$db->get_row($result816)){ $answer=$b['answer']; $search = array("\n", "&", """, "'", "\", """, "'", "<", ">"); $replace = array("\r\n", "&", "\"", "'", "\\", '\"', "\'", "<", ">"); $answer= str_replace($replace, $search, $answer); $checkforum1 =$db->super_query("SELECT COUNT(*) as count FROM newanswerthread WHERE answer='$answer' and weblog = '$weblog'"); $checkforumcount=$checkforum1['count']; if($checkforumcount > 1){ $checkforumcount1=$checkforumcount - 1; $result815 = $db->query("SELECT a_id FROM newanswerthread where weblog = '$weblog' and answer ='$answer' order by a_id desc limit 0,$checkforumcount1"); while($d=$db->get_row($result815)){ $aid=$d['a_id']; $sql23 = "DELETE FROM newanswerthread where weblog = '$weblog' and a_id='$aid'"; $result23 = $db->query($sql23); } } } } $db->query("UPDATE Users SET how6='1' WHERE w_id='$w_id'"); include('adsprocess2.php'); //java start $javastart = $db->super_query("SELECT code FROM upjava where weblog = '$weblog'"); $search_array5 = Array("<", ">", "\"","'","&"); $replace_array5 = Array("<", ">", ""","'","&"); $javastart['code'] = str_replace($replace_array5,$search_array5, $javastart['code']); echo $javastart["code"]; //finish //input blog $template = str_replace("[-Forget-]","/Forget", $template); if(isset($_POST['Login'])){ if(isset($_POST['username'])){ $usernme= htmlspecialchars($_POST['username']); }else { $usernme =''; } if(isset($_POST['password'])){ $password= htmlspecialchars($_POST['password']); }else{ $password=''; } @$usernme= strtolower($usernme); @$usernme= $db->safesql($usernme); @$password= strtolower($password); @$password= $db->safesql($password); $checkusernme =$db->query("SELECT * FROM members where username='$usernme' and password='$password' and weblog = '$weblog' and act='1'"); $user=between("", "", $template); if($usernme==""){ $template = str_replace("".$user."", "لطفا نام کاربری را وارد کنید
بازگشت", $template); } elseif($password==""){ $template = str_replace("".$user."", "لطفا رمز عبور را وارد کنید
بازگشت", $template); } elseif($db->num_rows($checkusernme)>0) { $db->query("DELETE FROM blogonline WHERE ip = '$ip' and useronline='0' and weblog = '$weblog'"); $membe =$db->super_query("SELECT m_id FROM members where username='$usernme' and password='$password' and weblog='$weblog'"); $s1=md5('memberid'.date("Ymd").'-'.$weblog); $s2=md5('username'.date("Ymd").'-'.$weblog); $_SESSION["$s1"] = $membe['m_id']; $_SESSION["$s2"] = $usernme; $template = str_replace("".$user."", "شما با موفقيت وارد اكانت خود شده ايد
خروج", $template); } else { $template = str_replace("".$user."", "نام كاربري يا رمز عبور اشتباه وارد شده است
بازگشت", $template); } } //end //start register if(isset($_GET['register'])){ $BlogSticky=between("", "", $template); $template = str_replace("".$BlogSticky."", "", $template); $comment=between("", "", $template); $template = str_replace("".$comment."", "", $template); $BlogPages=between("", "", $template); $template = str_replace("".$BlogPages."", "", $template); $Blogentire=between("", "", $template); $template = str_replace("".$Blogentire."", "", $template); $lastforums=between("", "", $template); $template = str_replace("".$lastforums."", "", $template); $ac='1'; if(isset($_POST['SendRegister'])){ if(isset($_SESSION["$s2"])){ $template = str_replace("[-Templates-]", "شما قبلا عضو شده ايد و دوباره نمي توانيد عضو شويد
بازگشت", $template); } else { if(isset($_POST['name'])){ @$name= $_POST['name']; } else { @$name= ''; } if(isset($_POST['usrname'])){ @$usrname= $_POST['usrname']; } else { @$usrname= ''; } if(isset($_POST['repassword'])){ @$repassword= $_POST['repassword']; } else { @$repassword= ''; } if(isset($_POST['password'])){ @$password= $_POST['password']; } else { @$password= ''; } if(isset($_POST['eml'])){ @$eml= $_POST['eml']; } else { @$eml= ''; } if(isset($_POST['seccode'])){ @$seccode= $_POST['seccode']; } else { @$seccode= ''; } @$name= htmlspecialchars($name); @$usrname= htmlspecialchars($usrname); @$repassword = htmlspecialchars($repassword); @$password = htmlspecialchars($password); @$eml= htmlspecialchars($eml); @$seccode= htmlspecialchars($seccode); @$name= addslashes($name); @$usrname= addslashes($usrname); @$repassword = addslashes($repassword); @$password = addslashes($password); @$eml= addslashes($eml); @$seccode= addslashes($seccode); @$name= strtolower($name); @$usrname= strtolower($usrname); @$repassword = strtolower($repassword); @$password = strtolower($password); @$seccode= strtolower($seccode); @$usrname= $db->safesql($usrname); @$password= $db->safesql($password); @$eml= $db->safesql($eml); $checkusernamemember=$db->query("SELECT * FROM members where username='$usrname' and weblog='$weblog'"); $checkemailmember=$db->query("SELECT * FROM members where email='$eml' and weblog='$weblog'"); if($db->num_rows($checkusernamemember)>0){ $template = str_replace("[-Templates-]", "نام كاربري انتخاب شده قبلا ثبت شده است لطفا نام ديگري انتخاب كنيد
بازگشت", $template); } elseif($db->num_rows($checkemailmember)>0){ $template = str_replace("[-Templates-]", "پست الكترونيك انتخاب شده قبلا ثبت شده است لطفا نام ديگري انتخاب كنيد
بازگشت", $template); } elseif($name==""){ $template = str_replace("[-Templates-]", "لطفا نام واقعي كاربر را وارد كنيد
بازگشت", $template); } elseif($usrname==""){ $template = str_replace("[-Templates-]", "لطفا نام كاربري را وارد كنيد
بازگشت", $template); } elseif($password ==""){ $template = str_replace("[-Templates-]", "لطفا رمز عبور را وارد كنيد
بازگشت", $template); } elseif($password != "$repassword"){ $template = str_replace("[-Templates-]", "رمز عبور با تکرار آن مطابقت ندارد
بازگشت", $template); } elseif($eml==""){ $template = str_replace("[-Templates-]", "لطفا پست الكترونيك را وارد كنيد
بازگشت", $template); } elseif(!eregi('^[a-zA-Z0-9_\-\.]+@[a-zA-Z0-9\-]+\.[a-zA-Z0-9\-\.]+$', $eml)){ $template = str_replace("[-Templates-]", "لطفا پست الكترونيك را درست وارد كنيد
بازگشت", $template); } elseif($seccode==""){ $template = str_replace("[-Templates-]", "لطفا كد امنيتي بالا را وارد كنيد
بازگشت", $template); } elseif(strtolower($_SESSION['security_code']) != $seccode){ $template = str_replace("[-Templates-]", "كد امنيتي اشتباه وارد شده است،دوباره تلاش كنيد
بازگشت‌", $template); } else { if($signupact=="0"){ $act='1'; } else { $act='0'; } $add_time = time(); $todatedate = date ("Y-m-d", $add_time); $db->query("INSERT INTO members(w_id,name,username,password,email,weblog,date,act)VALUES('$w_id','$name','$usrname','$password','$eml','$weblog','$todatedate','$act')"); $template = str_replace("[-Templates-]", "نام كاربري مورد نظر با موفقيت ساخته شد
بازگشت‌", $template); } } } else { $template = str_replace("[-Templates-]", "$signuptemplate", $template); // INPUT [-regster_Form-] $RegisterForm= occurrencecount("", "", $template, "0"); for($f=0;$f<$RegisterForm;$f++) { $insert = ""; $Form= between("", "", $template); $insert .= "
".$Form."
"; $insert = str_replace("[-Register_Name_Form-]","", $insert); $insert = str_replace("[-Register_usrname_Form-]"," ", $insert); $insert = str_replace("[-Register_password_Form-]","", $insert); $insert = str_replace("[-Register_repassword_Form-]","", $insert); $insert = str_replace("[-Register_Email_Form-]","", $insert); $insert = str_replace("[-Register_Term_Form-]","قوانين سایت", $insert); $insert = str_replace("[-Register_Security_Image_Form-]","", $insert); $insert = str_replace("[-Register_Security_Form-]","", $insert); $insert = str_replace("[-Register_Button_Form-]","", $insert); $template = str_replace("".$Form."", $insert, $template); } //FINISH } } else { $ac='0'; } //end register //start contact if(isset($_GET['contact'])){ $BlogSticky=between("", "", $template); $template = str_replace("".$BlogSticky."", "", $template); $comment=between("", "", $template); $template = str_replace("".$comment."", "", $template); $BlogPages=between("", "", $template); $template = str_replace("".$BlogPages."", "", $template); $Blogentire=between("", "", $template); $template = str_replace("".$Blogentire."", "", $template); $lastforums=between("", "", $template); $template = str_replace("".$lastforums."", "", $template); $ac2='1'; if(isset($_POST['sendmail'])){ $result =$db->query("SELECT * FROM Users where txtweblog = '$weblog'"); while($r=$db->get_row($result)) { $w_id=$r["w_id"]; $txtemail=$r["txtemail"]; } if(isset($_POST['eml'])){ @$eml= $_POST['eml']; } else { @$eml= ''; } if(isset($_POST['Contact'])){ @$Contact= $_POST['Contact']; } else { @$Contact= ''; } if(isset($_POST['seccode'])){ @$seccode= $_POST['seccode']; } else { @$seccode= ''; } $subject='Contact-us['.$eml.']'; $headers="From:no-reply@blogveb.com\r\nContent-Type:text/html;CHARSET=utf-8\r\n"; if($eml==""){ $template = str_replace("[-Templates-]", "لطفا پست الكترونيك را وارد كنيد
بازگشت", $template); } elseif($Contact==""){ $template = str_replace("[-Templates-]", "لطفا نظر را وارد كنيد
بازگشت", $template); } elseif(!eregi('^[a-zA-Z0-9_\-\.]+@[a-zA-Z0-9\-]+\.[a-zA-Z0-9\-\.]+$', $eml)){ $template = str_replace("[-Templates-]", "لطفا پست الكترونيك را درست وارد كنيد
بازگشت", $template); } elseif($seccode==""){ $template = str_replace("[-Templates-]", "لطفا كد امنيتي بالا را وارد كنيد
بازگشت", $template); } elseif(strtolower($_SESSION['security_code']) != $seccode){ $template = str_replace("[-Templates-]", "كد امنيتي اشتباه وارد شده است،دوباره تلاش كنيد
بازگشت", $template); } else { mail($txtemail, $subject, $Contact, $headers); $template = str_replace("[-Templates-]", "پيام شما با موفقيت ارسال شده است
بازگشت", $template); } } else { $template = str_replace("[-Templates-]", "$contacttemplate", $template); // INPUT [-regster_Form-] $RegisterForm= occurrencecount("", "", $template, "0"); for($f=0;$f<$RegisterForm;$f++) { $insert = ""; $Form= between("", "", $template); $insert .= "
".$Form."
"; $insert = str_replace("[-Contact_Your_Email_Form-]","", $insert); $insert = str_replace("[-Contact_Pm_Form-]","", $insert); $insert = str_replace("[-Contact_Security_Image_Form-]","", $insert); $insert = str_replace("[-Contact_Security_Form-]","", $insert); $insert = str_replace("[-Contact_Button_Form-]","", $insert); $template = str_replace("".$Form."", $insert, $template); } //FINISH } } else { $ac2='0'; } //end contact //start term if(isset($_GET['Logout'])){ $BlogSticky=between("", "", $template); $template = str_replace("".$BlogSticky."", "", $template); $comment=between("", "", $template); $template = str_replace("".$comment."", "", $template); $BlogPages=between("", "", $template); $template = str_replace("".$BlogPages."", "", $template); $Blogentire=between("", "", $template); $template = str_replace("".$Blogentire."", "", $template); $lastforums=between("", "", $template); $template = str_replace("".$lastforums."", "", $template); $user=$_SESSION["$s2"]; $db->query("DELETE FROM blogonline WHERE useronline='1' and weblog = '$weblog' and username= '$user'"); unset($_SESSION["$s1"]); unset($_SESSION["$s2"]); $template= str_replace("[-Templates-]", "باموفقیت خارج شده اید.", $template); header("Location: http://$domain"); $ac11='1'; } else { $ac11='0'; } //end friend //start news if(isset($_GET['news'])){ $BlogSticky=between("", "", $template); $template = str_replace("".$BlogSticky."", "", $template); $comment=between("", "", $template); $template = str_replace("".$comment."", "", $template); $BlogPages=between("", "", $template); $template = str_replace("".$BlogPages."", "", $template); $Blogentire=between("", "", $template); $template = str_replace("".$Blogentire."", "", $template); $lastforums=between("", "", $template); $template = str_replace("".$lastforums."", "", $template); $ac3='1'; //news $template = str_replace("[-Templates-]", "$news", $template); // INPUT [-LinkUrl-] , [-LinkTitle-] $nid=$_GET['nid']; $News= occurrencecount("", "", $template, "0"); for($f=0;$f<$News;$f++) { $insert = ""; $new= between("", "", $template); $result = $db->query("SELECT * FROM news WHERE weblog = '$weblog' and n_id='$nid'"); while($r=$db->get_row($result)){ $insert .= $new; $search_array5 = Array("<", ">", "\"","'","&"); $replace_array5 = Array("<", ">", ""","'","&"); $r['content'] = str_replace($replace_array5,$search_array5, $r['content']); $insert = str_replace("[-News_Title-]", "$r[title]", $insert); if($r['source']=="0"){ $insert = str_replace("[-News_Source-]", "ندارد", $insert); } else { $insert = str_replace("[-News_Source-]", "$r[source]", $insert); } $insert = str_replace("[-News_Content-]", "$r[content]", $insert); } $template = str_replace("".$new."", $insert, $template); } //FINISH //end news } else { $ac3='0'; } //end contact //start add link if(isset($_GET['AddLink'])){ $BlogSticky=between("", "", $template); $template = str_replace("".$BlogSticky."", "", $template); $comment=between("", "", $template); $template = str_replace("".$comment."", "", $template); $BlogPages=between("", "", $template); $template = str_replace("".$BlogPages."", "", $template); $Blogentire=between("", "", $template); $template = str_replace("".$Blogentire."", "", $template); $lastforums=between("", "", $template); $template = str_replace("".$lastforums."", "", $template); $ac10='1'; if(isset($_POST['sendlink'])){ if(isset($_POST['adress'])){ @$adress= $_POST['adress']; } else { @$adress= ''; } if(isset($_POST['name'])){ @$name= $_POST['name']; } else { @$name= ''; } if(isset($_POST['seccode'])){ @$seccode= $_POST['seccode']; } else { @$seccode= ''; } if($name==""){ $template = str_replace("[-Templates-]", "لطفا نام لینک را وارد كنيد
بازگشت", $template); } elseif($adress==""){ $template = str_replace("[-Templates-]", "لطفا آدرس لينك را وارد كنيد
بازگشت", $template); } elseif($seccode==""){ $template = str_replace("[-Templates-]", "لطفا كد امنيتي را وارد كنيد
بازگشت", $template); } elseif(strtolower($_SESSION['security_code']) != $seccode){ $template = str_replace("[-Templates-]", "كد امنيتي اشتباه وارد شده است،دوباره تلاش كنيد
بازگشت", $template); } else { $html = file_get_contents($adress) or problem(t('Can\'t open remote URL!')); if(strstr($html, $txttitle) and strstr($html, $domain)){ $db->query("INSERT INTO links (w_id,name,adress,weblog,act)VALUES('$w_id','$name','$adress','$weblog','0')"); $template = str_replace("[-Templates-]", "لينك با موفقيت ارسال شد
بازگشت", $template); } else { $template = str_replace("[-Templates-]", "لینک ما در سایت شما وجود ندارد
بازگشت", $template); } } } else { $addlink="
نام لينك:
آدرس لينك:
 
كد امنيتي:
 
"; $template = str_replace("[-Templates-]", "$addlink", $template); } } else { $ac10='0'; } //end addlink //start Profile if(isset($_GET['Profile'])){ $BlogSticky=between("", "", $template); $template = str_replace("".$BlogSticky."", "", $template); $BlogPages=between("", "", $template); $comment=between("", "", $template); $template = str_replace("".$comment."", "", $template); $template = str_replace("".$BlogPages."", "", $template); $Blogentire=between("", "", $template); $template = str_replace("".$Blogentire."", "", $template); $lastforums=between("", "", $template); $template = str_replace("".$lastforums."", "", $template); $ac4='1'; //news $result = $db->query("SELECT * FROM profile where weblog = '$weblog'"); while($r=$db->get_row($result)) { $chkProfile=$r["chkProfile"]; $Firstname=$r["txtFirstname"]; $Lastname=$r["txtLastname"]; $BirthDay=$r["txtBirthDay"]; $BirthMonth=$r["cmbBirthMonth"]; $BirthYear=$r["txtBirthYear"]; $Gender=$r["cmbGender"]; $Country=$r["txtCountry"]; $CityName=$r["txtCityName"]; $AboutMe=$r["txtAboutMe"]; $Email=$r["txtEmail"]; $Yahoo=$r["txtYahoo"]; $EducationLevel=$r["cmbEducationLevel"]; $Education=$r["txtEducation"]; $University=$r["txtUniversity"]; $Profession=$r["txtProfession"]; $Fav=$r["txtFav"]; if($db->num_rows($result)==0){ $chkProfile="OFF"; } else { $chkProfile=$r["chkProfile"]; } if($Firstname==""){ $txtFirstname="---"; } else { $txtFirstname = $r["txtFirstname"]; } if($Lastname==""){ $txtLastname="---"; } else { $txtLastname= $r["txtLastname"]; } if($BirthDay==""){ $txtBirthDay="---"; } else { $txtBirthDay= $r["txtBirthDay"]; } if($BirthMonth==""){ $cmbBirthMonth="---"; } else { $cmbBirthMonth= $r["cmbBirthMonth"]; } if($BirthYear==""){ $txtBirthYear="---"; } else { $txtBirthYear= $r["txtBirthYear"]; } if($Gender=="0"){ $cmbGender="---"; } elseif($Gender=="1"){ $cmbGender= "زن"; } elseif($Gender=="2"){ $cmbGender= "مرد"; } else { $cmbGender="---"; } if($Country==""){ $txtCountry="---"; } else { $txtCountry= $r["txtCountry"]; } if($CityName==""){ $txtCityName="---"; } else { $txtCityName= $r["txtCityName"]; } if($AboutMe==""){ $txtAboutMe="---"; } else { $txtAboutMe= $r["txtAboutMe"]; } if($Email==""){ $txtEmail="---"; } else { $txtEmail= $r["txtEmail"]; } if($Yahoo==""){ $txtYahoo="---"; } else { $txtYahoo= $r["txtYahoo"]; } if($EducationLevel=="0"){ $cmbEducationLevel="---"; } elseif($EducationLevel=="1"){ $cmbEducationLevel="دانش آموز"; } elseif($EducationLevel=="2"){ $cmbEducationLevel="دانش آموز پیش دانشگاهی"; } elseif($EducationLevel=="3"){ $cmbEducationLevel="زیر دیپلم"; } elseif($EducationLevel=="4"){ $cmbEducationLevel="دیپلم"; } elseif($EducationLevel=="5"){ $cmbEducationLevel="دانشجو"; } elseif($EducationLevel=="6"){ $cmbEducationLevel="فوق دیپلم"; } elseif($EducationLevel=="7"){ $cmbEducationLevel="کارشناسی"; } elseif($EducationLevel=="8"){ $cmbEducationLevel="دانشجوی کارشناسی ارشد"; } elseif($EducationLevel=="9"){ $cmbEducationLevel="کارشناسی ارشد"; } elseif($EducationLevel=="10"){ $cmbEducationLevel="دکتری"; } else { $cmbEducationLevel="---"; } if($Education==""){ $txtEducation="---"; } else { $txtEducation= $r["txtEducation"]; } if($University==""){ $txtUniversity="---"; } else { $txtUniversity= $r["txtUniversity"]; } if($Profession==""){ $txtProfession="---"; } else { $txtProfession= $r["txtProfession"]; } if($Fav==""){ $txtFav="---"; } else { $txtFav= $r["txtFav"]; } } if($chkProfile=="OFF"){ $profile="
پروفايل مدير سايت غير فعال است
"; } else { $profile="
نام:
$txtFirstname
نام خانوادگي:
$txtLastname
تاريخ تولد:
$txtBirthDay / $cmbBirthMonth / $txtBirthYear
جنسيت:
$cmbGender
كشور: $txtCountry
شهر: $txtCityName
درباره من: $txtAboutMe
پست الكترونيك: $txtEmail
شناسه Yahoo: $txtYahoo
سطح تحصيلات: $cmbEducationLevel
رشته تحصيلي: $txtEducation
محل تحصيل: $txtUniversity
مهارت هاي كاري $txtProfession
علائق: $txtFav
"; } $template = str_replace("[-Templates-]", "$profile", $template); //end profile } else { $ac4='0'; } //end profile //start poll if(isset($_GET['Poll'])){ $BlogSticky=between("", "", $template); $template = str_replace("".$BlogSticky."", "", $template); $comment=between("", "", $template); $template = str_replace("".$comment."", "", $template); $BlogPages=between("", "", $template); $template = str_replace("".$BlogPages."", "", $template); $Blogentire=between("", "", $template); $template = str_replace("".$Blogentire."", "", $template); $lastforums=between("", "", $template); $template = str_replace("".$lastforums."", "", $template); $ac5='1'; $poll=""; if(isset($_POST['Poll'])){ $checkpoll = $db->query("SELECT * FROM question WHERE weblog = '$weblog' and how= '1'"); if($db->num_rows($checkpoll)=="0"){ $poll="
نظر سنجي براي اين وبلاگ فعال نمي باشد
"; } else { $result = $db->query("SELECT * FROM question where weblog = '$weblog' and how='1'"); while($r=$db->get_row($result)) { $totalvotes=$r["totalvotes"]; $q_id=$r["q_id"]; } $checkip = $db->query("SELECT * FROM Pollip WHERE ip='$ip' AND weblog = '$weblog' and q_id='$q_id'"); if($db->num_rows($checkip)>0) { $poll="
شما قبلا در نظرسنجی سایت شرکت کرده اید دیگر نمی توانید رای دهید
"; } else { $result = $db->query("SELECT * FROM question where weblog = '$weblog' and how='1'"); while($r=$db->get_row($result)) { $totalvotes=$r["totalvotes"]; $q_id=$r["q_id"]; } if(isset($_POST['answer'])){ $poll = $_POST['answer']; $resultanswer= $db->query("SELECT * FROM answer where weblog = '$weblog' AND a_id='$poll' and q_id='$q_id'"); while($r=$db->get_row($resultanswer)) { $votes=$r["votes"]; } $db->query("UPDATE question SET totalvotes=totalvotes + 1 WHERE weblog = '$weblog' and how='1' and q_id='$q_id'"); $db->query("UPDATE answer SET votes=votes + 1 WHERE weblog = '$weblog' and a_id = '$poll'"); $db->query("INSERT INTO Pollip (ip,weblog,q_id)VALUES('$ip','$weblog','$q_id')"); $poll="
جواب شما با موفقیت به سیستم ارسال شده است
"; } } } } //result $result = $db->query("SELECT * FROM question where weblog = '$weblog' and how='1'"); if($db->num_rows($result)>0){ while($r=$db->get_row($result)) { $totalvotes=$r["totalvotes"]; $question=$r["question"]; $q_id=$r["q_id"]; } } else { $totalvotes=''; $question=''; $q_id=''; } $poll .= ""; $result =$db->query("SELECT * FROM answer where weblog = '$weblog' and q_id='$q_id'"); $i=1; while($r=$db->get_row($result)) { $votes=$r["votes"]; $answer=$r["answer"]; if($votes=="0"){ $proc = "1"; $rproc=round($proc) - 1; } else { $proc = ($votes * 100 / $totalvotes); $rproc=round($proc); } $poll .=""; $i++; } $poll .="
$question
$answer
 تعداد آرا: $votes $rproc %
"; //end res $template = str_replace("[-Templates-]", "$poll", $template); } else { $ac5='0'; } //end poll //start poll archive if(isset($_GET['PollArchive'])){ $BlogSticky=between("", "", $template); $template = str_replace("".$BlogSticky."", "", $template); $comment=between("", "", $template); $template = str_replace("".$comment."", "", $template); $BlogPages=between("", "", $template); $template = str_replace("".$BlogPages."", "", $template); $Blogentire=between("", "", $template); $template = str_replace("".$Blogentire."", "", $template); $lastforums=between("", "", $template); $template = str_replace("".$lastforums."", "", $template); $ac13='1'; $poll=""; //result $result = $db->query("SELECT * FROM question where weblog = '$weblog'"); if($db->num_rows($result)>0){ while($b=$db->get_row($result)) { $totalvotes=$b["totalvotes"]; $question=$b["question"]; $q_id=$b["q_id"]; $poll .= ""; $result1 =$db->query("SELECT * FROM answer where weblog = '$weblog' and q_id='$q_id'"); $i=1; while($r=$db->get_row($result1)) { $votes=$r["votes"]; $answer=$r["answer"]; if($votes=="0"){ $proc = "1"; $rproc=round($proc) - 1; } else { $proc = ($votes * 100 / $totalvotes); $rproc=round($proc); } $poll .=""; $i++; } $poll .="
$question
$answer
$rproc %  تعداد آرا: $votes $rproc %

"; } } else { $totalvotes=''; $question=''; $q_id=''; } //end res $template = str_replace("[-Templates-]", "$poll", $template); } else { $ac13='0'; } //end poll //start newsletter if(isset($_GET['NewsLetter'])){ $BlogSticky=between("", "", $template); $template = str_replace("".$BlogSticky."", "", $template); $comment=between("", "", $template); $template = str_replace("".$comment."", "", $template); $BlogPages=between("", "", $template); $template = str_replace("".$BlogPages."", "", $template); $Blogentire=between("", "", $template); $template = str_replace("".$Blogentire."", "", $template); $lastforums=between("", "", $template); $template = str_replace("".$lastforums."", "", $template); $ac6='1'; if(isset($_POST['NewsLetter'])){ if(isset($_POST['Email'])){ $Email= $_POST['Email']; } else { $Email= ''; } if(isset($_POST['Action'])){ $Action= $_POST['Action']; } else { $Action= ''; } if($Email==""){ $template = str_replace("[-Templates-]", "لطفا پست الكترونيك را وارد كنيد
بازگشت", $template); } elseif(!eregi('^[a-zA-Z0-9_\-\.]+@[a-zA-Z0-9\-]+\.[a-zA-Z0-9\-\.]+$', $Email)){ $template = str_replace("[-Templates-]", "لطفا پست الكترونيك را درست وارد كنيد
بازگشت", $template); } else { //for add if($Action=="Add"){ $checkemail = $db->query("SELECT * FROM newsletter WHERE email = '$Email' and weblog='$weblog'"); if($db->num_rows($checkemail)>0) { $template = str_replace("[-Templates-]", "اين پست الكترونيك قبلا ثبت شده است
بازگشت", $template); } else { $db->query("INSERT INTO newsletter (w_id,email,weblog)VALUES('$w_id','$Email','$weblog')"); $template = str_replace("[-Templates-]", "پست الكترونيك شما با موفقيت اضافه شد
بازگشت", $template); } } else { $checkemail = $db->query("SELECT * FROM newsletter WHERE email = '$Email' and weblog='$weblog'"); if($db->num_rows($checkemail)==0) { $template = str_replace("[-Templates-]", "اين پست الكترونيك ثبت نشده است
بازگشت", $template); } else { $sql = "DELETE FROM newsletter WHERE weblog='$weblog' and email='$Email'"; $result5 = $db->query($sql); $template = str_replace("[-Templates-]", "پست الكترونيك مورد نظر با موفقيت حذف شد
بازگشت", $template); } } //end } } else { $template = str_replace("[-Templates-]", "", $template); } } else { $ac6='0'; } //end contact //start friend if(isset($_GET['Friends'])){ $BlogSticky=between("", "", $template); $template = str_replace("".$BlogSticky."", "", $template); $comment=between("", "", $template); $template = str_replace("".$comment."", "", $template); $BlogPages=between("", "", $template); $template = str_replace("".$BlogPages."", "", $template); $Blogentire=between("", "", $template); $template = str_replace("".$Blogentire."", "", $template); $lastforums=between("", "", $template); $template = str_replace("".$lastforums."", "", $template); $ac7='1'; if(isset($_POST['Friend'])){ if(isset($_POST['sec'])){ $sec=$_POST['seccode']; if(isset($_POST['MyEmail'])){ $MyEmail= $_POST['MyEmail']; } else { $MyEmail= ''; } if(isset($_POST['FriendEmail'])){ $FriendEmail= $_POST['FriendEmail']; } else { $FriendEmail= ''; } if($MyEmail==""){ $template = str_replace("[-Templates-]", "لطفا پست الكترونيك خود را وارد كنيد
بازگشت", $template); } elseif($FriendEmail==""){ $template = str_replace("[-Templates-]", "لطفا پست الكترونيك دوست خود را وارد كنيد
بازگشت", $template); } elseif(!eregi('^[a-zA-Z0-9_\-\.]+@[a-zA-Z0-9\-]+\.[a-zA-Z0-9\-\.]+$', $MyEmail)){ $template = str_replace("[-Templates-]", "لطفا پست الكترونيك خود را درست وارد كنيد
بازگشت", $template); } elseif(!eregi('^[a-zA-Z0-9_\-\.]+@[a-zA-Z0-9\-]+\.[a-zA-Z0-9\-\.]+$', $FriendEmail)){ $template = str_replace("[-Templates-]", "لطفا پست الكترونيك دوست خود را درست وارد كنيد
بازگشت", $template); } elseif($sec==""){ $template = str_replace("[-Templates-]", "لطفا كد امنيتي را وارد كنيد
بازگشت", $template); } elseif(strtolower($_SESSION['security_code']) != $sec){ $template = str_replace("[-Templates-]", "كد امنيتي اشتباه وارد شده است،دوباره تلاش كنيد
بازگشت‌", $template); } else { $friend = $db->query("SELECT * FROM friend where weblog = '$weblog'"); while($r=$db->get_row($friend)) { $pm=$r["pm"]; $search_array5 = Array("<", ">", "\"","'"); $replace_array5 = Array("<", ">", ""","'"); $pm= str_replace($replace_array5,$search_array5, $pm); } $headers="From:$MyEmail\r\nContent-Type:text/html;CHARSET=utf-8\r\n"; mail($FriendEmail, "moarefi yek site tOOp", $pm, $headers); $template = str_replace("[-Templates-]", "پیام با موفقیت ارسال شد
بازگشت", $template); } } else { if(isset($_POST['MyEmail'])){ $MyEmail= $_POST['MyEmail']; } else { $MyEmail= ''; } if(isset($_POST['FriendEmail'])){ $FriendEmail= $_POST['FriendEmail']; } else { $FriendEmail= ''; } if($MyEmail==""){ $template = str_replace("[-Templates-]", "لطفا پست الكترونيك خود را وارد كنيد
بازگشت", $template); } elseif($FriendEmail==""){ $template = str_replace("[-Templates-]", "لطفا پست الكترونيك دوست خود را وارد كنيد
بازگشت", $template); } elseif(!eregi('^[a-zA-Z0-9_\-\.]+@[a-zA-Z0-9\-]+\.[a-zA-Z0-9\-\.]+$', $MyEmail)){ $template = str_replace("[-Templates-]", "لطفا پست الكترونيك خود را درست وارد كنيد
بازگشت", $template); } elseif(!eregi('^[a-zA-Z0-9_\-\.]+@[a-zA-Z0-9\-]+\.[a-zA-Z0-9\-\.]+$', $FriendEmail)){ $template = str_replace("[-Templates-]", "لطفا پست الكترونيك دوست خود را درست وارد كنيد
بازگشت", $template); } else { $template = str_replace("[-Templates-]", "
لطفا کد زیر را در کادر وارد فرمایید
 
", $template); } } } else { $template = str_replace("[-Templates-]", "", $template); } } else { $ac7='0'; } //end friend if(isset($_GET['Rate'])){ $BlogSticky=between("", "", $template); $template = str_replace("".$BlogSticky."", "", $template); $BlogPages=between("", "", $template); $template = str_replace("".$BlogPages."", "", $template); $Blogentire=between("", "", $template); $template = str_replace("".$Blogentire."", "", $template); $lastforums=between("", "", $template); $template = str_replace("".$lastforums."", "", $template); $ac8='1'; if(isset($_GET['eid'])){ if(isset($_GET['id'])){ $eid=$_GET['eid']; $id=$_GET['id']; if($id=="1" or $id=="2" or $id=="3" or $id=="4" or $id=="5"){ $result = $db->query("SELECT * FROM entires WHERE weblog = '$weblog' and e_id='$eid' and how = '1'"); while($r=$db->get_row($result)){ $db->query("UPDATE entires SET totalvotes=$r[totalvotes] + $id WHERE weblog = '$weblog' and e_id='$eid'"); $db->query("UPDATE entires SET uservotes=$r[uservotes] + 1 WHERE weblog = '$weblog' and e_id='$eid'"); $template = str_replace("[-Templates-]", "امتياز شما با موفقيت اضافه شد
بازگشت", $template); } } else { $template = str_replace("[-Templates-]", "امتياز شما باید بین 1 تا 5 باشد.
بازگشت", $template); } } } } else { $ac8='0'; } //end friend //start term if(isset($_GET['Terms'])){ $BlogSticky=between("", "", $template); $template = str_replace("".$BlogSticky."", "", $template); $comment=between("", "", $template); $template = str_replace("".$comment."", "", $template); $BlogPages=between("", "", $template); $template = str_replace("".$BlogPages."", "", $template); $Blogentire=between("", "", $template); $template = str_replace("".$Blogentire."", "", $template); $lastforums=between("", "", $template); $template = str_replace("".$lastforums."", "", $template); $Term = $db->query("SELECT * FROM term where weblog = '$weblog'"); $ac9='1'; while($r=$db->get_row($Term)) { $term=$r["term"]; $template = str_replace("[-Templates-]", "$term", $template); } } else { $ac9='0'; } //start Forget if(isset($_GET['Forget'])){ $BlogSticky=between("", "", $template); $template = str_replace("".$BlogSticky."", "", $template); $comment=between("", "", $template); $template = str_replace("".$comment."", "", $template); $BlogPages=between("", "", $template); $template = str_replace("".$BlogPages."", "", $template); $Blogentire=between("", "", $template); $template = str_replace("".$Blogentire."", "", $template); $lastforums=between("", "", $template); $template = str_replace("".$lastforums."", "", $template); $ac12='1'; if(isset($_POST['sendpass'])){ if(isset($_POST['emails'])){ @$emails= htmlspecialchars($_POST['emails']); } else { @$emails= ''; } $checkemailmember=$db->query("SELECT * FROM members where email='$emails' and weblog='$weblog'"); if($emails==""){ $template = str_replace("[-Templates-]", "لطفا پست الکترونیک را وارد کنید.
بازگشت", $template); } elseif(!eregi('^[a-zA-Z0-9_\-\.]+@[a-zA-Z0-9\-]+\.[a-zA-Z0-9\-\.]+$', $emails)){ $template = str_replace("[-Templates-]", "لطفا پست الکترونیک را درست وارد کنید.
بازگشت", $template); } else { if($db->num_rows($checkemailmember)>0){ $friend = $db->query("SELECT * FROM members where email='$emails' and weblog='$weblog'"); while($r=$db->get_row($friend)) { $username=$r["username"]; $password=$r["password"]; } $headers="From:no-reply@blogveb.com\r\nContent-Type:text/html;CHARSET=utf-8\r\n"; $subject="Forget Password in $domain"; $temp="
 $username نام کاربری:
 $password رمز عبور:
"; mail($emails, $subject, $temp, $headers); $template = str_replace("[-Templates-]", "رمز عبور با موفقیت ارسال شده است.
بازگشت", $template); } else { $template = str_replace("[-Templates-]", "چنین پست الکترونیکی در سایت ثبت نشده است.
بازگشت", $template); } } } else { $addlink="
لطفا آدرس ایمیل خود را وارد کنید تا کلمه عبور برای شما ارسال شود :
مثال: example@domain.com
"; $template = str_replace("[-Templates-]", "$addlink", $template); } } else { $ac12='0'; } //end forget if($ac=="0" and $ac2=="0" and $ac3=="0" and $ac4=="0" and $ac5=="0" and $ac6=="0" and $ac7=="0" and $ac8=="0" and $ac9=="0" and $ac10=="0" and $ac11=="0" and $ac12=="0" and $ac13=="0"){ $Blogtemplates=between("", "", $template); $template = str_replace("".$Blogtemplates."", "", $template); } //end friend include('blog/yahoo-mp3.php'); include('blog/profile-photo.php'); include('blog/sticky.php'); include('blog/mainmenu.php'); include('blog/maincat.php'); include('blog/author.php'); include('blog/menus.php'); include('blog/previ.php'); include('blog/Links.php'); include('blog/Login.php'); include('blog/morepage.php'); include('blog/news.php'); include('blog/static.php'); include('blog/poll.php'); include('blog/newsletter.php'); include('blog/friend.php'); include('blog/news.php'); include('blog/search.php'); include('blog/montharchive.php'); include('blog/tag.php'); include('blog/lastforum.php'); include('blog/online-users.php'); include('blog/fastregister.php'); if(isset($_GET['Terms'])){ //static $add_time = time(); $todatedate = date("Y-m-d", $add_time); $year = jgmdate("Y", $add_time); $month = jgmdate("m", $add_time); $timestamp=time(); $timeoutseconds= "300"; $timeout=$timestamp-$timeoutseconds; if(isset($_SERVER['HTTP_REFERER'])){ @$referer= htmlspecialchars($_SERVER['HTTP_REFERER']); @$referer= addslashes($referer); $refereract='1'; } else { $referer=''; $refereract='0'; } if(isset($_SESSION["$s2"])){ $useronline=$_SESSION["$s2"]; $useronlines='1'; } else { $useronline=''; $useronlines='0'; } $checkstatic1 = $db->query("SELECT * FROM blogonline WHERE ip='$ip' and weblog='$weblog'"); if($db->num_rows($checkstatic1)==0){ $db->query("INSERT INTO blogonline (w_id,weblog,ip,date,timestamp,useronline,username)VALUES('$w_id','$weblog','$ip','$todatedate','$timestamp','$useronlines','$useronline')"); } $db->free($checkstatic1); $db->query("DELETE FROM blogonline WHERE timestamp<$timeout and weblog = '$weblog'"); //end static //new static //result static blog $newstatic =$db->super_query("SELECT * FROM newstatic where weblog = '$weblog'"); $today=$newstatic["today"]; $lastday=$newstatic["lastday"]; $total=$newstatic["total"]; $todayhit=$newstatic["todayhit"]; $lastdayhit=$newstatic["lastdayhit"]; $months=$newstatic["month"]; $years=$newstatic["year"]; $monthcal=$newstatic["monthcal"]; $yearcal=$newstatic["yearcal"]; $date=$newstatic["date"]; if($date != "$todatedate"){ $db->query("UPDATE newstatic SET lastday='$today' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET lastdayhit='$todayhit' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET todayhit='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET date='$todatedate' WHERE weblog = '$weblog'"); } $db->query("UPDATE newstatic SET total=total+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today=today+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET month=month+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET year=year+1 WHERE weblog = '$weblog'"); if($monthcal!="$month"){ $db->query("UPDATE newstatic SET month='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET monthcal='$month' WHERE weblog = '$weblog'"); } if($yearcal!="$year"){ $db->query("UPDATE newstatic SET year='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET yearcal='$year' WHERE weblog = '$weblog'"); } $db->query("INSERT INTO static (w_id,weblog,ip,date,year,month,referer,refereract)VALUES('$w_id','$weblog','$ip','$todatedate','$year','$month','$referer','$refereract')"); //finish static //end new static } if(isset($_GET['uprate'])){ //static $add_time = time(); $todatedate = date("Y-m-d", $add_time); $year = jgmdate("Y", $add_time); $month = jgmdate("m", $add_time); $timestamp=time(); $timeoutseconds= "300"; $timeout=$timestamp-$timeoutseconds; if(isset($_SERVER['HTTP_REFERER'])){ @$referer= htmlspecialchars($_SERVER['HTTP_REFERER']); @$referer= addslashes($referer); $refereract='1'; } else { $referer=''; $refereract='0'; } if(isset($_SESSION["$s2"])){ $useronline=$_SESSION["$s2"]; $useronlines='1'; } else { $useronline=''; $useronlines='0'; } $checkstatic1 = $db->query("SELECT * FROM blogonline WHERE ip='$ip' and weblog='$weblog'"); if($db->num_rows($checkstatic1)==0){ $db->query("INSERT INTO blogonline (w_id,weblog,ip,date,timestamp,useronline,username)VALUES('$w_id','$weblog','$ip','$todatedate','$timestamp','$useronlines','$useronline')"); } $db->free($checkstatic1); $db->query("DELETE FROM blogonline WHERE timestamp<$timeout and weblog = '$weblog'"); //end static //new static //result static blog $newstatic =$db->super_query("SELECT * FROM newstatic where weblog = '$weblog'"); $today=$newstatic["today"]; $lastday=$newstatic["lastday"]; $total=$newstatic["total"]; $todayhit=$newstatic["todayhit"]; $lastdayhit=$newstatic["lastdayhit"]; $months=$newstatic["month"]; $years=$newstatic["year"]; $monthcal=$newstatic["monthcal"]; $yearcal=$newstatic["yearcal"]; $date=$newstatic["date"]; if($date != "$todatedate"){ $db->query("UPDATE newstatic SET lastday='$today' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET lastdayhit='$todayhit' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET todayhit='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET date='$todatedate' WHERE weblog = '$weblog'"); } $db->query("UPDATE newstatic SET total=total+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today=today+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET month=month+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET year=year+1 WHERE weblog = '$weblog'"); if($monthcal!="$month"){ $db->query("UPDATE newstatic SET month='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET monthcal='$month' WHERE weblog = '$weblog'"); } if($yearcal!="$year"){ $db->query("UPDATE newstatic SET year='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET yearcal='$year' WHERE weblog = '$weblog'"); } $db->query("INSERT INTO static (w_id,weblog,ip,date,year,month,referer,refereract)VALUES('$w_id','$weblog','$ip','$todatedate','$year','$month','$referer','$refereract')"); //finish static //end new static } if(isset($_GET['downrate'])){ //static $add_time = time(); $todatedate = date("Y-m-d", $add_time); $year = jgmdate("Y", $add_time); $month = jgmdate("m", $add_time); $timestamp=time(); $timeoutseconds= "300"; $timeout=$timestamp-$timeoutseconds; if(isset($_SERVER['HTTP_REFERER'])){ @$referer= htmlspecialchars($_SERVER['HTTP_REFERER']); @$referer= addslashes($referer); $refereract='1'; } else { $referer=''; $refereract='0'; } if(isset($_SESSION["$s2"])){ $useronline=$_SESSION["$s2"]; $useronlines='1'; } else { $useronline=''; $useronlines='0'; } $checkstatic1 = $db->query("SELECT * FROM blogonline WHERE ip='$ip' and weblog='$weblog'"); if($db->num_rows($checkstatic1)==0){ $db->query("INSERT INTO blogonline (w_id,weblog,ip,date,timestamp,useronline,username)VALUES('$w_id','$weblog','$ip','$todatedate','$timestamp','$useronlines','$useronline')"); } $db->free($checkstatic1); $db->query("DELETE FROM blogonline WHERE timestamp<$timeout and weblog = '$weblog'"); //end static //new static //result static blog $newstatic =$db->super_query("SELECT * FROM newstatic where weblog = '$weblog'"); $today=$newstatic["today"]; $lastday=$newstatic["lastday"]; $total=$newstatic["total"]; $todayhit=$newstatic["todayhit"]; $lastdayhit=$newstatic["lastdayhit"]; $months=$newstatic["month"]; $years=$newstatic["year"]; $monthcal=$newstatic["monthcal"]; $yearcal=$newstatic["yearcal"]; $date=$newstatic["date"]; if($date != "$todatedate"){ $db->query("UPDATE newstatic SET lastday='$today' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET lastdayhit='$todayhit' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET todayhit='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET date='$todatedate' WHERE weblog = '$weblog'"); } $db->query("UPDATE newstatic SET total=total+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today=today+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET month=month+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET year=year+1 WHERE weblog = '$weblog'"); if($monthcal!="$month"){ $db->query("UPDATE newstatic SET month='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET monthcal='$month' WHERE weblog = '$weblog'"); } if($yearcal!="$year"){ $db->query("UPDATE newstatic SET year='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET yearcal='$year' WHERE weblog = '$weblog'"); } $db->query("INSERT INTO static (w_id,weblog,ip,date,year,month,referer,refereract)VALUES('$w_id','$weblog','$ip','$todatedate','$year','$month','$referer','$refereract')"); //finish static //end new static } if(isset($_GET['Friends'])){ //static $add_time = time(); $todatedate = date("Y-m-d", $add_time); $year = jgmdate("Y", $add_time); $month = jgmdate("m", $add_time); $timestamp=time(); $timeoutseconds= "300"; $timeout=$timestamp-$timeoutseconds; if(isset($_SERVER['HTTP_REFERER'])){ @$referer= htmlspecialchars($_SERVER['HTTP_REFERER']); @$referer= addslashes($referer); $refereract='1'; } else { $referer=''; $refereract='0'; } if(isset($_SESSION["$s2"])){ $useronline=$_SESSION["$s2"]; $useronlines='1'; } else { $useronline=''; $useronlines='0'; } $checkstatic1 = $db->query("SELECT * FROM blogonline WHERE ip='$ip' and weblog='$weblog'"); if($db->num_rows($checkstatic1)==0){ $db->query("INSERT INTO blogonline (w_id,weblog,ip,date,timestamp,useronline,username)VALUES('$w_id','$weblog','$ip','$todatedate','$timestamp','$useronlines','$useronline')"); } $db->free($checkstatic1); $db->query("DELETE FROM blogonline WHERE timestamp<$timeout and weblog = '$weblog'"); //end static //new static //result static blog $newstatic =$db->super_query("SELECT * FROM newstatic where weblog = '$weblog'"); $today=$newstatic["today"]; $lastday=$newstatic["lastday"]; $total=$newstatic["total"]; $todayhit=$newstatic["todayhit"]; $lastdayhit=$newstatic["lastdayhit"]; $months=$newstatic["month"]; $years=$newstatic["year"]; $monthcal=$newstatic["monthcal"]; $yearcal=$newstatic["yearcal"]; $date=$newstatic["date"]; if($date != "$todatedate"){ $db->query("UPDATE newstatic SET lastday='$today' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET lastdayhit='$todayhit' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET todayhit='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET date='$todatedate' WHERE weblog = '$weblog'"); } $db->query("UPDATE newstatic SET total=total+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today=today+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET month=month+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET year=year+1 WHERE weblog = '$weblog'"); if($monthcal!="$month"){ $db->query("UPDATE newstatic SET month='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET monthcal='$month' WHERE weblog = '$weblog'"); } if($yearcal!="$year"){ $db->query("UPDATE newstatic SET year='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET yearcal='$year' WHERE weblog = '$weblog'"); } $db->query("INSERT INTO static (w_id,weblog,ip,date,year,month,referer,refereract)VALUES('$w_id','$weblog','$ip','$todatedate','$year','$month','$referer','$refereract')"); //finish static //end new static } if(isset($_GET['NewsLetter'])){ //static $add_time = time(); $todatedate = date("Y-m-d", $add_time); $year = jgmdate("Y", $add_time); $month = jgmdate("m", $add_time); $timestamp=time(); $timeoutseconds= "300"; $timeout=$timestamp-$timeoutseconds; if(isset($_SERVER['HTTP_REFERER'])){ @$referer= htmlspecialchars($_SERVER['HTTP_REFERER']); @$referer= addslashes($referer); $refereract='1'; } else { $referer=''; $refereract='0'; } if(isset($_SESSION["$s2"])){ $useronline=$_SESSION["$s2"]; $useronlines='1'; } else { $useronline=''; $useronlines='0'; } $checkstatic1 = $db->query("SELECT * FROM blogonline WHERE ip='$ip' and weblog='$weblog'"); if($db->num_rows($checkstatic1)==0){ $db->query("INSERT INTO blogonline (w_id,weblog,ip,date,timestamp,useronline,username)VALUES('$w_id','$weblog','$ip','$todatedate','$timestamp','$useronlines','$useronline')"); } $db->free($checkstatic1); $db->query("DELETE FROM blogonline WHERE timestamp<$timeout and weblog = '$weblog'"); //end static //new static //result static blog $newstatic =$db->super_query("SELECT * FROM newstatic where weblog = '$weblog'"); $today=$newstatic["today"]; $lastday=$newstatic["lastday"]; $total=$newstatic["total"]; $todayhit=$newstatic["todayhit"]; $lastdayhit=$newstatic["lastdayhit"]; $months=$newstatic["month"]; $years=$newstatic["year"]; $monthcal=$newstatic["monthcal"]; $yearcal=$newstatic["yearcal"]; $date=$newstatic["date"]; if($date != "$todatedate"){ $db->query("UPDATE newstatic SET lastday='$today' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET lastdayhit='$todayhit' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET todayhit='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET date='$todatedate' WHERE weblog = '$weblog'"); } $db->query("UPDATE newstatic SET total=total+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today=today+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET month=month+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET year=year+1 WHERE weblog = '$weblog'"); if($monthcal!="$month"){ $db->query("UPDATE newstatic SET month='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET monthcal='$month' WHERE weblog = '$weblog'"); } if($yearcal!="$year"){ $db->query("UPDATE newstatic SET year='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET yearcal='$year' WHERE weblog = '$weblog'"); } $db->query("INSERT INTO static (w_id,weblog,ip,date,year,month,referer,refereract)VALUES('$w_id','$weblog','$ip','$todatedate','$year','$month','$referer','$refereract')"); //finish static //end new static } if(isset($_GET['Poll'])){ //static $add_time = time(); $todatedate = date("Y-m-d", $add_time); $year = jgmdate("Y", $add_time); $month = jgmdate("m", $add_time); $timestamp=time(); $timeoutseconds= "300"; $timeout=$timestamp-$timeoutseconds; if(isset($_SERVER['HTTP_REFERER'])){ @$referer= htmlspecialchars($_SERVER['HTTP_REFERER']); @$referer= addslashes($referer); $refereract='1'; } else { $referer=''; $refereract='0'; } if(isset($_SESSION["$s2"])){ $useronline=$_SESSION["$s2"]; $useronlines='1'; } else { $useronline=''; $useronlines='0'; } $checkstatic1 = $db->query("SELECT * FROM blogonline WHERE ip='$ip' and weblog='$weblog'"); if($db->num_rows($checkstatic1)==0){ $db->query("INSERT INTO blogonline (w_id,weblog,ip,date,timestamp,useronline,username)VALUES('$w_id','$weblog','$ip','$todatedate','$timestamp','$useronlines','$useronline')"); } $db->free($checkstatic1); $db->query("DELETE FROM blogonline WHERE timestamp<$timeout and weblog = '$weblog'"); //end static //new static //result static blog $newstatic =$db->super_query("SELECT * FROM newstatic where weblog = '$weblog'"); $today=$newstatic["today"]; $lastday=$newstatic["lastday"]; $total=$newstatic["total"]; $todayhit=$newstatic["todayhit"]; $lastdayhit=$newstatic["lastdayhit"]; $months=$newstatic["month"]; $years=$newstatic["year"]; $monthcal=$newstatic["monthcal"]; $yearcal=$newstatic["yearcal"]; $date=$newstatic["date"]; if($date != "$todatedate"){ $db->query("UPDATE newstatic SET lastday='$today' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET lastdayhit='$todayhit' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET todayhit='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET date='$todatedate' WHERE weblog = '$weblog'"); } $db->query("UPDATE newstatic SET total=total+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today=today+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET month=month+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET year=year+1 WHERE weblog = '$weblog'"); if($monthcal!="$month"){ $db->query("UPDATE newstatic SET month='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET monthcal='$month' WHERE weblog = '$weblog'"); } if($yearcal!="$year"){ $db->query("UPDATE newstatic SET year='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET yearcal='$year' WHERE weblog = '$weblog'"); } $db->query("INSERT INTO static (w_id,weblog,ip,date,year,month,referer,refereract)VALUES('$w_id','$weblog','$ip','$todatedate','$year','$month','$referer','$refereract')"); //finish static //end new static } if(isset($_GET['Profile'])){ //static $add_time = time(); $todatedate = date("Y-m-d", $add_time); $year = jgmdate("Y", $add_time); $month = jgmdate("m", $add_time); $timestamp=time(); $timeoutseconds= "300"; $timeout=$timestamp-$timeoutseconds; if(isset($_SERVER['HTTP_REFERER'])){ @$referer= htmlspecialchars($_SERVER['HTTP_REFERER']); @$referer= addslashes($referer); $refereract='1'; } else { $referer=''; $refereract='0'; } if(isset($_SESSION["$s2"])){ $useronline=$_SESSION["$s2"]; $useronlines='1'; } else { $useronline=''; $useronlines='0'; } $checkstatic1 = $db->query("SELECT * FROM blogonline WHERE ip='$ip' and weblog='$weblog'"); if($db->num_rows($checkstatic1)==0){ $db->query("INSERT INTO blogonline (w_id,weblog,ip,date,timestamp,useronline,username)VALUES('$w_id','$weblog','$ip','$todatedate','$timestamp','$useronlines','$useronline')"); } $db->free($checkstatic1); $db->query("DELETE FROM blogonline WHERE timestamp<$timeout and weblog = '$weblog'"); //end static //new static //result static blog $newstatic =$db->super_query("SELECT * FROM newstatic where weblog = '$weblog'"); $today=$newstatic["today"]; $lastday=$newstatic["lastday"]; $total=$newstatic["total"]; $todayhit=$newstatic["todayhit"]; $lastdayhit=$newstatic["lastdayhit"]; $months=$newstatic["month"]; $years=$newstatic["year"]; $monthcal=$newstatic["monthcal"]; $yearcal=$newstatic["yearcal"]; $date=$newstatic["date"]; if($date != "$todatedate"){ $db->query("UPDATE newstatic SET lastday='$today' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET lastdayhit='$todayhit' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET todayhit='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET date='$todatedate' WHERE weblog = '$weblog'"); } $db->query("UPDATE newstatic SET total=total+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today=today+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET month=month+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET year=year+1 WHERE weblog = '$weblog'"); if($monthcal!="$month"){ $db->query("UPDATE newstatic SET month='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET monthcal='$month' WHERE weblog = '$weblog'"); } if($yearcal!="$year"){ $db->query("UPDATE newstatic SET year='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET yearcal='$year' WHERE weblog = '$weblog'"); } $db->query("INSERT INTO static (w_id,weblog,ip,date,year,month,referer,refereract)VALUES('$w_id','$weblog','$ip','$todatedate','$year','$month','$referer','$refereract')"); //finish static //end new static } if(isset($_GET['AddLink'])){ //static $add_time = time(); $todatedate = date("Y-m-d", $add_time); $year = jgmdate("Y", $add_time); $month = jgmdate("m", $add_time); $timestamp=time(); $timeoutseconds= "300"; $timeout=$timestamp-$timeoutseconds; if(isset($_SERVER['HTTP_REFERER'])){ @$referer= htmlspecialchars($_SERVER['HTTP_REFERER']); @$referer= addslashes($referer); $refereract='1'; } else { $referer=''; $refereract='0'; } if(isset($_SESSION["$s2"])){ $useronline=$_SESSION["$s2"]; $useronlines='1'; } else { $useronline=''; $useronlines='0'; } $checkstatic1 = $db->query("SELECT * FROM blogonline WHERE ip='$ip' and weblog='$weblog'"); if($db->num_rows($checkstatic1)==0){ $db->query("INSERT INTO blogonline (w_id,weblog,ip,date,timestamp,useronline,username)VALUES('$w_id','$weblog','$ip','$todatedate','$timestamp','$useronlines','$useronline')"); } $db->free($checkstatic1); $db->query("DELETE FROM blogonline WHERE timestamp<$timeout and weblog = '$weblog'"); //end static //new static //result static blog $newstatic =$db->super_query("SELECT * FROM newstatic where weblog = '$weblog'"); $today=$newstatic["today"]; $lastday=$newstatic["lastday"]; $total=$newstatic["total"]; $todayhit=$newstatic["todayhit"]; $lastdayhit=$newstatic["lastdayhit"]; $months=$newstatic["month"]; $years=$newstatic["year"]; $monthcal=$newstatic["monthcal"]; $yearcal=$newstatic["yearcal"]; $date=$newstatic["date"]; if($date != "$todatedate"){ $db->query("UPDATE newstatic SET lastday='$today' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET lastdayhit='$todayhit' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET todayhit='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET date='$todatedate' WHERE weblog = '$weblog'"); } $db->query("UPDATE newstatic SET total=total+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today=today+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET month=month+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET year=year+1 WHERE weblog = '$weblog'"); if($monthcal!="$month"){ $db->query("UPDATE newstatic SET month='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET monthcal='$month' WHERE weblog = '$weblog'"); } if($yearcal!="$year"){ $db->query("UPDATE newstatic SET year='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET yearcal='$year' WHERE weblog = '$weblog'"); } $db->query("INSERT INTO static (w_id,weblog,ip,date,year,month,referer,refereract)VALUES('$w_id','$weblog','$ip','$todatedate','$year','$month','$referer','$refereract')"); //finish static //end new static } if(isset($_GET['Logout'])){ //static $add_time = time(); $todatedate = date("Y-m-d", $add_time); $year = jgmdate("Y", $add_time); $month = jgmdate("m", $add_time); $timestamp=time(); $timeoutseconds= "300"; $timeout=$timestamp-$timeoutseconds; if(isset($_SERVER['HTTP_REFERER'])){ @$referer= htmlspecialchars($_SERVER['HTTP_REFERER']); @$referer= addslashes($referer); $refereract='1'; } else { $referer=''; $refereract='0'; } if(isset($_SESSION["$s2"])){ $useronline=$_SESSION["$s2"]; $useronlines='1'; } else { $useronline=''; $useronlines='0'; } $checkstatic1 = $db->query("SELECT * FROM blogonline WHERE ip='$ip' and weblog='$weblog'"); if($db->num_rows($checkstatic1)==0){ $db->query("INSERT INTO blogonline (w_id,weblog,ip,date,timestamp,useronline,username)VALUES('$w_id','$weblog','$ip','$todatedate','$timestamp','$useronlines','$useronline')"); } $db->free($checkstatic1); $db->query("DELETE FROM blogonline WHERE timestamp<$timeout and weblog = '$weblog'"); //end static //new static //result static blog $newstatic =$db->super_query("SELECT * FROM newstatic where weblog = '$weblog'"); $today=$newstatic["today"]; $lastday=$newstatic["lastday"]; $total=$newstatic["total"]; $todayhit=$newstatic["todayhit"]; $lastdayhit=$newstatic["lastdayhit"]; $months=$newstatic["month"]; $years=$newstatic["year"]; $monthcal=$newstatic["monthcal"]; $yearcal=$newstatic["yearcal"]; $date=$newstatic["date"]; if($date != "$todatedate"){ $db->query("UPDATE newstatic SET lastday='$today' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET lastdayhit='$todayhit' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET todayhit='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET date='$todatedate' WHERE weblog = '$weblog'"); } $db->query("UPDATE newstatic SET total=total+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today=today+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET month=month+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET year=year+1 WHERE weblog = '$weblog'"); if($monthcal!="$month"){ $db->query("UPDATE newstatic SET month='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET monthcal='$month' WHERE weblog = '$weblog'"); } if($yearcal!="$year"){ $db->query("UPDATE newstatic SET year='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET yearcal='$year' WHERE weblog = '$weblog'"); } $db->query("INSERT INTO static (w_id,weblog,ip,date,year,month,referer,refereract)VALUES('$w_id','$weblog','$ip','$todatedate','$year','$month','$referer','$refereract')"); //finish static //end new static } if(isset($_GET['contact'])){ //static $add_time = time(); $todatedate = date("Y-m-d", $add_time); $year = jgmdate("Y", $add_time); $month = jgmdate("m", $add_time); $timestamp=time(); $timeoutseconds= "300"; $timeout=$timestamp-$timeoutseconds; if(isset($_SERVER['HTTP_REFERER'])){ @$referer= htmlspecialchars($_SERVER['HTTP_REFERER']); @$referer= addslashes($referer); $refereract='1'; } else { $referer=''; $refereract='0'; } if(isset($_SESSION["$s2"])){ $useronline=$_SESSION["$s2"]; $useronlines='1'; } else { $useronline=''; $useronlines='0'; } $checkstatic1 = $db->query("SELECT * FROM blogonline WHERE ip='$ip' and weblog='$weblog'"); if($db->num_rows($checkstatic1)==0){ $db->query("INSERT INTO blogonline (w_id,weblog,ip,date,timestamp,useronline,username)VALUES('$w_id','$weblog','$ip','$todatedate','$timestamp','$useronlines','$useronline')"); } $db->free($checkstatic1); $db->query("DELETE FROM blogonline WHERE timestamp<$timeout and weblog = '$weblog'"); //end static //new static //result static blog $newstatic =$db->super_query("SELECT * FROM newstatic where weblog = '$weblog'"); $today=$newstatic["today"]; $lastday=$newstatic["lastday"]; $total=$newstatic["total"]; $todayhit=$newstatic["todayhit"]; $lastdayhit=$newstatic["lastdayhit"]; $months=$newstatic["month"]; $years=$newstatic["year"]; $monthcal=$newstatic["monthcal"]; $yearcal=$newstatic["yearcal"]; $date=$newstatic["date"]; if($date != "$todatedate"){ $db->query("UPDATE newstatic SET lastday='$today' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET lastdayhit='$todayhit' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET todayhit='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET date='$todatedate' WHERE weblog = '$weblog'"); } $db->query("UPDATE newstatic SET total=total+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today=today+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET month=month+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET year=year+1 WHERE weblog = '$weblog'"); if($monthcal!="$month"){ $db->query("UPDATE newstatic SET month='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET monthcal='$month' WHERE weblog = '$weblog'"); } if($yearcal!="$year"){ $db->query("UPDATE newstatic SET year='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET yearcal='$year' WHERE weblog = '$weblog'"); } $db->query("INSERT INTO static (w_id,weblog,ip,date,year,month,referer,refereract)VALUES('$w_id','$weblog','$ip','$todatedate','$year','$month','$referer','$refereract')"); //finish static //end new static } if(isset($_GET['register'])){ //static $add_time = time(); $todatedate = date("Y-m-d", $add_time); $year = jgmdate("Y", $add_time); $month = jgmdate("m", $add_time); $timestamp=time(); $timeoutseconds= "300"; $timeout=$timestamp-$timeoutseconds; if(isset($_SERVER['HTTP_REFERER'])){ @$referer= htmlspecialchars($_SERVER['HTTP_REFERER']); @$referer= addslashes($referer); $refereract='1'; } else { $referer=''; $refereract='0'; } if(isset($_SESSION["$s2"])){ $useronline=$_SESSION["$s2"]; $useronlines='1'; } else { $useronline=''; $useronlines='0'; } $checkstatic1 = $db->query("SELECT * FROM blogonline WHERE ip='$ip' and weblog='$weblog'"); if($db->num_rows($checkstatic1)==0){ $db->query("INSERT INTO blogonline (w_id,weblog,ip,date,timestamp,useronline,username)VALUES('$w_id','$weblog','$ip','$todatedate','$timestamp','$useronlines','$useronline')"); } $db->free($checkstatic1); $db->query("DELETE FROM blogonline WHERE timestamp<$timeout and weblog = '$weblog'"); //end static //new static //result static blog $newstatic =$db->super_query("SELECT * FROM newstatic where weblog = '$weblog'"); $today=$newstatic["today"]; $lastday=$newstatic["lastday"]; $total=$newstatic["total"]; $todayhit=$newstatic["todayhit"]; $lastdayhit=$newstatic["lastdayhit"]; $months=$newstatic["month"]; $years=$newstatic["year"]; $monthcal=$newstatic["monthcal"]; $yearcal=$newstatic["yearcal"]; $date=$newstatic["date"]; if($date != "$todatedate"){ $db->query("UPDATE newstatic SET lastday='$today' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET lastdayhit='$todayhit' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET todayhit='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET date='$todatedate' WHERE weblog = '$weblog'"); } $db->query("UPDATE newstatic SET total=total+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today=today+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET month=month+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET year=year+1 WHERE weblog = '$weblog'"); if($monthcal!="$month"){ $db->query("UPDATE newstatic SET month='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET monthcal='$month' WHERE weblog = '$weblog'"); } if($yearcal!="$year"){ $db->query("UPDATE newstatic SET year='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET yearcal='$year' WHERE weblog = '$weblog'"); } $db->query("INSERT INTO static (w_id,weblog,ip,date,year,month,referer,refereract)VALUES('$w_id','$weblog','$ip','$todatedate','$year','$month','$referer','$refereract')"); //finish static //end new static } if(isset($_GET['Login'])){ //static $add_time = time(); $todatedate = date("Y-m-d", $add_time); $year = jgmdate("Y", $add_time); $month = jgmdate("m", $add_time); $timestamp=time(); $timeoutseconds= "300"; $timeout=$timestamp-$timeoutseconds; if(isset($_SERVER['HTTP_REFERER'])){ @$referer= htmlspecialchars($_SERVER['HTTP_REFERER']); @$referer= addslashes($referer); $refereract='1'; } else { $referer=''; $refereract='0'; } if(isset($_SESSION["$s2"])){ $useronline=$_SESSION["$s2"]; $useronlines='1'; } else { $useronline=''; $useronlines='0'; } $checkstatic1 = $db->query("SELECT * FROM blogonline WHERE ip='$ip' and weblog='$weblog'"); if($db->num_rows($checkstatic1)==0){ $db->query("INSERT INTO blogonline (w_id,weblog,ip,date,timestamp,useronline,username)VALUES('$w_id','$weblog','$ip','$todatedate','$timestamp','$useronlines','$useronline')"); } $db->free($checkstatic1); $db->query("DELETE FROM blogonline WHERE timestamp<$timeout and weblog = '$weblog'"); //end static //new static //result static blog $newstatic =$db->super_query("SELECT * FROM newstatic where weblog = '$weblog'"); $today=$newstatic["today"]; $lastday=$newstatic["lastday"]; $total=$newstatic["total"]; $todayhit=$newstatic["todayhit"]; $lastdayhit=$newstatic["lastdayhit"]; $months=$newstatic["month"]; $years=$newstatic["year"]; $monthcal=$newstatic["monthcal"]; $yearcal=$newstatic["yearcal"]; $date=$newstatic["date"]; if($date != "$todatedate"){ $db->query("UPDATE newstatic SET lastday='$today' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET lastdayhit='$todayhit' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET todayhit='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET date='$todatedate' WHERE weblog = '$weblog'"); } $db->query("UPDATE newstatic SET total=total+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today=today+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET month=month+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET year=year+1 WHERE weblog = '$weblog'"); if($monthcal!="$month"){ $db->query("UPDATE newstatic SET month='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET monthcal='$month' WHERE weblog = '$weblog'"); } if($yearcal!="$year"){ $db->query("UPDATE newstatic SET year='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET yearcal='$year' WHERE weblog = '$weblog'"); } $db->query("INSERT INTO static (w_id,weblog,ip,date,year,month,referer,refereract)VALUES('$w_id','$weblog','$ip','$todatedate','$year','$month','$referer','$refereract')"); //finish static //end new static } if(isset($_GET['news'])){ //static $add_time = time(); $todatedate = date("Y-m-d", $add_time); $year = jgmdate("Y", $add_time); $month = jgmdate("m", $add_time); $timestamp=time(); $timeoutseconds= "300"; $timeout=$timestamp-$timeoutseconds; if(isset($_SERVER['HTTP_REFERER'])){ @$referer= htmlspecialchars($_SERVER['HTTP_REFERER']); @$referer= addslashes($referer); $refereract='1'; } else { $referer=''; $refereract='0'; } if(isset($_SESSION["$s2"])){ $useronline=$_SESSION["$s2"]; $useronlines='1'; } else { $useronline=''; $useronlines='0'; } $checkstatic1 = $db->query("SELECT * FROM blogonline WHERE ip='$ip' and weblog='$weblog'"); if($db->num_rows($checkstatic1)==0){ $db->query("INSERT INTO blogonline (w_id,weblog,ip,date,timestamp,useronline,username)VALUES('$w_id','$weblog','$ip','$todatedate','$timestamp','$useronlines','$useronline')"); } $db->free($checkstatic1); $db->query("DELETE FROM blogonline WHERE timestamp<$timeout and weblog = '$weblog'"); //end static //new static //result static blog $newstatic =$db->super_query("SELECT * FROM newstatic where weblog = '$weblog'"); $today=$newstatic["today"]; $lastday=$newstatic["lastday"]; $total=$newstatic["total"]; $todayhit=$newstatic["todayhit"]; $lastdayhit=$newstatic["lastdayhit"]; $months=$newstatic["month"]; $years=$newstatic["year"]; $monthcal=$newstatic["monthcal"]; $yearcal=$newstatic["yearcal"]; $date=$newstatic["date"]; if($date != "$todatedate"){ $db->query("UPDATE newstatic SET lastday='$today' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET lastdayhit='$todayhit' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET todayhit='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET date='$todatedate' WHERE weblog = '$weblog'"); } $db->query("UPDATE newstatic SET total=total+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today=today+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET month=month+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET year=year+1 WHERE weblog = '$weblog'"); if($monthcal!="$month"){ $db->query("UPDATE newstatic SET month='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET monthcal='$month' WHERE weblog = '$weblog'"); } if($yearcal!="$year"){ $db->query("UPDATE newstatic SET year='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET yearcal='$year' WHERE weblog = '$weblog'"); } $db->query("INSERT INTO static (w_id,weblog,ip,date,year,month,referer,refereract)VALUES('$w_id','$weblog','$ip','$todatedate','$year','$month','$referer','$refereract')"); //finish static //end new static } if(!isset($_GET['Terms'])){ if(!isset($_GET['uprate'])){ if(!isset($_GET['downrate'])){ if(!isset($_GET['Friends'])){ if(!isset($_GET['NewsLetter'])){ if(!isset($_GET['Poll'])){ if(!isset($_GET['Profile'])){ if(!isset($_GET['AddLink'])){ if(!isset($_GET['news'])){ if(!isset($_GET['Logout'])){ if(!isset($_GET['contact'])){ if(!isset($_GET['register'])){ if(!isset($_GET['Login'])){ if(isset($_GET['Category'])){ $namecat=$_GET['namecat']; $search_array1 = Array("[-Title-]","[-BlogTitle-]", "[-BlogDescription-]","[-Blogid-]","[-BlogAdress-]","[-BlogEmail-]","[-Profile-]","[-Linkbox-]","[-Signup-]","[-Contact-]","[-RssAdress-]"); $replace_array1 = Array("$txttitle","$namecat - $txttitle", "$txtdescription","$weblog","$domain","$txtemail","/Profile","/Linkbox","/Register","/Contact","/Rss.xml"); $template = str_replace($search_array1,$replace_array1, $template); } elseif(isset($_GET['Author'])){ // INPUT [-BlogTitle-] , [-BlogDescription-],[-BlogAbout-],[-BlogPhoto-],[-BlogPhotoLink-] $search_array1 = Array("[-Title-]","[-BlogTitle-]", "[-BlogDescription-]","[-Blogid-]","[-BlogAdress-]","[-BlogEmail-]","[-Profile-]","[-Linkbox-]","[-Signup-]","[-Contact-]","[-RssAdress-]"); $replace_array1 = Array("$txttitle","$txttitle", "$txtdescription","$weblog","$domain","$txtemail","/Profile","/Linkbox","/Register","/Contact","/Rss.xml"); $template = str_replace($search_array1,$replace_array1, $template); } elseif(isset($_GET['Archive'])){ // INPUT [-BlogTitle-] , [-BlogDescription-],[-BlogAbout-],[-BlogPhoto-],[-BlogPhotoLink-] $search_array1 = Array("[-Title-]","[-BlogTitle-]", "[-BlogDescription-]","[-Blogid-]","[-BlogAdress-]","[-BlogEmail-]","[-Profile-]","[-Linkbox-]","[-Signup-]","[-Contact-]","[-RssAdress-]"); $replace_array1 = Array("$txttitle","$txttitle", "$txtdescription","$weblog","$domain","$txtemail","/Profile","/Linkbox","/Register","/Contact","/Rss.xml"); $template = str_replace($search_array1,$replace_array1, $template); } elseif(isset($_GET['Postpassword'])){ // INPUT [-BlogTitle-] , [-BlogDescription-],[-BlogAbout-],[-BlogPhoto-],[-BlogPhotoLink-] $search_array1 = Array("[-Title-]","[-BlogTitle-]", "[-BlogDescription-]","[-Blogid-]","[-BlogAdress-]","[-BlogEmail-]","[-Profile-]","[-Linkbox-]","[-Signup-]","[-Contact-]","[-RssAdress-]"); $replace_array1 = Array("$txttitle","$txttitle", "$txtdescription","$weblog","$domain","$txtemail","/Profile","/Linkbox","/Register","/Contact","/Rss.xml"); $template = str_replace($search_array1,$replace_array1, $template); } elseif(isset($_GET['More'])){ $tit=$_GET['tit']; // INPUT [-BlogTitle-] , [-BlogDescription-],[-BlogAbout-],[-BlogPhoto-],[-BlogPhotoLink-] $search_array1 = Array("[-Title-]","[-BlogTitle-]", "[-BlogDescription-]","[-Blogid-]","[-BlogAdress-]","[-BlogEmail-]","[-Profile-]","[-Linkbox-]","[-Signup-]","[-Contact-]","[-RssAdress-]"); $replace_array1 = Array("$txttitle","$tit - $txttitle", "$txtdescription","$weblog","$domain","$txtemail","/Profile","/Linkbox","/Register","/Contact","/Rss.xml"); $template = str_replace($search_array1,$replace_array1, $template); } elseif(isset($_GET['Tags'])){ $more=$_GET['tag']; // INPUT [-BlogTitle-] , [-BlogDescription-],[-BlogAbout-],[-BlogPhoto-],[-BlogPhotoLink-] $search_array1 = Array("[-Title-]","[-BlogTitle-]", "[-BlogDescription-]","[-Blogid-]","[-BlogAdress-]","[-BlogEmail-]","[-Profile-]","[-Linkbox-]","[-Signup-]","[-Contact-]","[-RssAdress-]"); $replace_array1 = Array("$txttitle","$more - $txttitle", "$txtdescription","$weblog","$domain","$txtemail","/Profile","/Linkbox","/Register","/Contact","/Rss.xml"); $template = str_replace($search_array1,$replace_array1, $template); } elseif(isset($_GET['Search'])){ //input blog if(isset($_GET['txt'])){ $txtsearch=$_GET['txt']; } else { if(isset($_POST['txtsearch'])){ $txtsearch=$_POST['txtsearch']; } else { $txtsearch=''; } } // INPUT [-BlogTitle-] , [-BlogDescription-],[-BlogAbout-],[-BlogPhoto-],[-BlogPhotoLink-] $search_array1 = Array("[-Title-]","[-BlogTitle-]", "[-BlogDescription-]","[-Blogid-]","[-BlogAdress-]","[-BlogEmail-]","[-Profile-]","[-Linkbox-]","[-Signup-]","[-Contact-]","[-RssAdress-]"); $replace_array1 = Array("$txttitle","$txttitle - $txtsearch", "$txtdescription","$weblog","$domain","$txtemail","/Profile","/Linkbox","/Register","/Contact","/Rss.xml"); $template = str_replace($search_array1,$replace_array1, $template); } else { // INPUT [-BlogTitle-] , [-BlogDescription-],[-BlogAbout-],[-BlogPhoto-],[-BlogPhotoLink-] $search_array1 = Array("[-Title-]","[-BlogTitle-]", "[-BlogDescription-]","[-Blogid-]","[-BlogAdress-]","[-BlogEmail-]","[-Profile-]","[-Linkbox-]","[-Signup-]","[-Contact-]","[-RssAdress-]"); $replace_array1 = Array("$txttitle","$txttitle", "$txtdescription","$weblog","$domain","$txtemail","/Profile","/Linkbox","/Register","/Contact","/Rss.xml"); $template = str_replace($search_array1,$replace_array1, $template); } }}}}}}}}}}}}} if(!isset($_GET['Terms'])){ if(!isset($_GET['uprate'])){ if(!isset($_GET['downrate'])){ if(!isset($_GET['Friends'])){ if(!isset($_GET['NewsLetter'])){ if(!isset($_GET['Poll'])){ if(!isset($_GET['Profile'])){ if(!isset($_GET['AddLink'])){ if(!isset($_GET['news'])){ if(!isset($_GET['Logout'])){ if(!isset($_GET['contact'])){ if(!isset($_GET['register'])){ if(!isset($_GET['Login'])){ if(isset($_GET['Category'])){ //static $add_time = time(); $todatedate = date("Y-m-d", $add_time); $year = jgmdate("Y", $add_time); $month = jgmdate("m", $add_time); $timestamp=time(); $timeoutseconds= "300"; $timeout=$timestamp-$timeoutseconds; if(isset($_SERVER['HTTP_REFERER'])){ @$referer= htmlspecialchars($_SERVER['HTTP_REFERER']); @$referer= addslashes($referer); $refereract='1'; } else { $referer=''; $refereract='0'; } if(isset($_SESSION["$s2"])){ $useronline=$_SESSION["$s2"]; $useronlines='1'; } else { $useronline=''; $useronlines='0'; } $checkstatic1 = $db->query("SELECT * FROM blogonline WHERE ip='$ip' and weblog='$weblog'"); if($db->num_rows($checkstatic1)==0){ $db->query("INSERT INTO blogonline (w_id,weblog,ip,date,timestamp,useronline,username)VALUES('$w_id','$weblog','$ip','$todatedate','$timestamp','$useronlines','$useronline')"); } $db->free($checkstatic1); $db->query("DELETE FROM blogonline WHERE timestamp<$timeout and weblog = '$weblog'"); //end static //new static //result static blog $newstatic =$db->super_query("SELECT * FROM newstatic where weblog = '$weblog'"); $today=$newstatic["today"]; $lastday=$newstatic["lastday"]; $total=$newstatic["total"]; $todayhit=$newstatic["todayhit"]; $lastdayhit=$newstatic["lastdayhit"]; $months=$newstatic["month"]; $years=$newstatic["year"]; $monthcal=$newstatic["monthcal"]; $yearcal=$newstatic["yearcal"]; $date=$newstatic["date"]; if($date != "$todatedate"){ $db->query("UPDATE newstatic SET lastday='$today' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET lastdayhit='$todayhit' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET todayhit='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET date='$todatedate' WHERE weblog = '$weblog'"); } $db->query("UPDATE newstatic SET total=total+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today=today+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET month=month+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET year=year+1 WHERE weblog = '$weblog'"); if($monthcal!="$month"){ $db->query("UPDATE newstatic SET month='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET monthcal='$month' WHERE weblog = '$weblog'"); } if($yearcal!="$year"){ $db->query("UPDATE newstatic SET year='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET yearcal='$year' WHERE weblog = '$weblog'"); } $db->query("INSERT INTO static (w_id,weblog,ip,date,year,month,referer,refereract)VALUES('$w_id','$weblog','$ip','$todatedate','$year','$month','$referer','$refereract')"); //finish static //end new static include('Category.php'); } elseif(isset($_GET['Author'])){ //static $add_time = time(); $todatedate = date("Y-m-d", $add_time); $year = jgmdate("Y", $add_time); $month = jgmdate("m", $add_time); $timestamp=time(); $timeoutseconds= "300"; $timeout=$timestamp-$timeoutseconds; if(isset($_SERVER['HTTP_REFERER'])){ @$referer= htmlspecialchars($_SERVER['HTTP_REFERER']); @$referer= addslashes($referer); $refereract='1'; } else { $referer=''; $refereract='0'; } if(isset($_SESSION["$s2"])){ $useronline=$_SESSION["$s2"]; $useronlines='1'; } else { $useronline=''; $useronlines='0'; } $checkstatic1 = $db->query("SELECT * FROM blogonline WHERE ip='$ip' and weblog='$weblog'"); if($db->num_rows($checkstatic1)==0){ $db->query("INSERT INTO blogonline (w_id,weblog,ip,date,timestamp,useronline,username)VALUES('$w_id','$weblog','$ip','$todatedate','$timestamp','$useronlines','$useronline')"); } $db->free($checkstatic1); $db->query("DELETE FROM blogonline WHERE timestamp<$timeout and weblog = '$weblog'"); //end static //new static $newstatic =$db->super_query("SELECT * FROM newstatic where weblog = '$weblog'"); $today=$newstatic["today"]; $lastday=$newstatic["lastday"]; $total=$newstatic["total"]; $todayhit=$newstatic["todayhit"]; $lastdayhit=$newstatic["lastdayhit"]; $months=$newstatic["month"]; $years=$newstatic["year"]; $monthcal=$newstatic["monthcal"]; $yearcal=$newstatic["yearcal"]; $date=$newstatic["date"]; if($date != "$todatedate"){ $db->query("UPDATE newstatic SET lastday='$today' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET lastdayhit='$todayhit' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET todayhit='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET date='$todatedate' WHERE weblog = '$weblog'"); } $db->query("UPDATE newstatic SET total=total+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today=today+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET month=month+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET year=year+1 WHERE weblog = '$weblog'"); if($monthcal!="$month"){ $db->query("UPDATE newstatic SET month='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET monthcal='$month' WHERE weblog = '$weblog'"); } if($yearcal!="$year"){ $db->query("UPDATE newstatic SET year='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET yearcal='$year' WHERE weblog = '$weblog'"); } $db->query("INSERT INTO static (w_id,weblog,ip,date,year,month,referer,refereract)VALUES('$w_id','$weblog','$ip','$todatedate','$year','$month','$referer','$refereract')"); //finish static //end new static include('Author.php'); } elseif(isset($_GET['Archive'])){ //static $add_time = time(); $todatedate = date("Y-m-d", $add_time); $year = jgmdate("Y", $add_time); $month = jgmdate("m", $add_time); $timestamp=time(); $timeoutseconds= "300"; $timeout=$timestamp-$timeoutseconds; if(isset($_SERVER['HTTP_REFERER'])){ @$referer= htmlspecialchars($_SERVER['HTTP_REFERER']); @$referer= addslashes($referer); $refereract='1'; } else { $referer=''; $refereract='0'; } if(isset($_SESSION["$s2"])){ $useronline=$_SESSION["$s2"]; $useronlines='1'; } else { $useronline=''; $useronlines='0'; } $checkstatic1 = $db->query("SELECT * FROM blogonline WHERE ip='$ip' and weblog='$weblog'"); if($db->num_rows($checkstatic1)==0){ $db->query("INSERT INTO blogonline (w_id,weblog,ip,date,timestamp,useronline,username)VALUES('$w_id','$weblog','$ip','$todatedate','$timestamp','$useronlines','$useronline')"); } $db->free($checkstatic1); $db->query("DELETE FROM blogonline WHERE timestamp<$timeout and weblog = '$weblog'"); //end static //new static $newstatic =$db->super_query("SELECT * FROM newstatic where weblog = '$weblog'"); $today=$newstatic["today"]; $lastday=$newstatic["lastday"]; $total=$newstatic["total"]; $todayhit=$newstatic["todayhit"]; $lastdayhit=$newstatic["lastdayhit"]; $months=$newstatic["month"]; $years=$newstatic["year"]; $monthcal=$newstatic["monthcal"]; $yearcal=$newstatic["yearcal"]; $date=$newstatic["date"]; if($date != "$todatedate"){ $db->query("UPDATE newstatic SET lastday='$today' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET lastdayhit='$todayhit' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET todayhit='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET date='$todatedate' WHERE weblog = '$weblog'"); } $db->query("UPDATE newstatic SET total=total+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today=today+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET month=month+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET year=year+1 WHERE weblog = '$weblog'"); if($monthcal!="$month"){ $db->query("UPDATE newstatic SET month='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET monthcal='$month' WHERE weblog = '$weblog'"); } if($yearcal!="$year"){ $db->query("UPDATE newstatic SET year='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET yearcal='$year' WHERE weblog = '$weblog'"); } $db->query("INSERT INTO static (w_id,weblog,ip,date,year,month,referer,refereract)VALUES('$w_id','$weblog','$ip','$todatedate','$year','$month','$referer','$refereract')"); //finish static //end new static include('Archive.php'); } elseif(isset($_GET['Postpassword'])){ //static $add_time = time(); $todatedate = date("Y-m-d", $add_time); $year = jgmdate("Y", $add_time); $month = jgmdate("m", $add_time); $timestamp=time(); $timeoutseconds= "300"; $timeout=$timestamp-$timeoutseconds; if(isset($_SERVER['HTTP_REFERER'])){ @$referer= htmlspecialchars($_SERVER['HTTP_REFERER']); @$referer= addslashes($referer); $refereract='1'; } else { $referer=''; $refereract='0'; } if(isset($_SESSION["$s2"])){ $useronline=$_SESSION["$s2"]; $useronlines='1'; } else { $useronline=''; $useronlines='0'; } $checkstatic1 = $db->query("SELECT * FROM blogonline WHERE ip='$ip' and weblog='$weblog'"); if($db->num_rows($checkstatic1)==0){ $db->query("INSERT INTO blogonline (w_id,weblog,ip,date,timestamp,useronline,username)VALUES('$w_id','$weblog','$ip','$todatedate','$timestamp','$useronlines','$useronline')"); } $db->free($checkstatic1); $db->query("DELETE FROM blogonline WHERE timestamp<$timeout and weblog = '$weblog'"); //end static //new static $newstatic =$db->super_query("SELECT * FROM newstatic where weblog = '$weblog'"); $today=$newstatic["today"]; $lastday=$newstatic["lastday"]; $total=$newstatic["total"]; $todayhit=$newstatic["todayhit"]; $lastdayhit=$newstatic["lastdayhit"]; $months=$newstatic["month"]; $years=$newstatic["year"]; $monthcal=$newstatic["monthcal"]; $yearcal=$newstatic["yearcal"]; $date=$newstatic["date"]; if($date != "$todatedate"){ $db->query("UPDATE newstatic SET lastday='$today' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET lastdayhit='$todayhit' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET todayhit='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET date='$todatedate' WHERE weblog = '$weblog'"); } $db->query("UPDATE newstatic SET total=total+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today=today+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET month=month+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET year=year+1 WHERE weblog = '$weblog'"); if($monthcal!="$month"){ $db->query("UPDATE newstatic SET month='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET monthcal='$month' WHERE weblog = '$weblog'"); } if($yearcal!="$year"){ $db->query("UPDATE newstatic SET year='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET yearcal='$year' WHERE weblog = '$weblog'"); } $db->query("INSERT INTO static (w_id,weblog,ip,date,year,month,referer,refereract)VALUES('$w_id','$weblog','$ip','$todatedate','$year','$month','$referer','$refereract')"); //finish static //end new static include('Postpassword.php'); } elseif(isset($_GET['More'])){ //static $add_time = time(); $todatedate = date("Y-m-d", $add_time); $year = jgmdate("Y", $add_time); $month = jgmdate("m", $add_time); $timestamp=time(); $timeoutseconds= "300"; $timeout=$timestamp-$timeoutseconds; if(isset($_SERVER['HTTP_REFERER'])){ @$referer= htmlspecialchars($_SERVER['HTTP_REFERER']); @$referer= addslashes($referer); $refereract='1'; } else { $referer=''; $refereract='0'; } if(isset($_SESSION["$s2"])){ $useronline=$_SESSION["$s2"]; $useronlines='1'; } else { $useronline=''; $useronlines='0'; } $checkstatic1 = $db->query("SELECT * FROM blogonline WHERE ip='$ip' and weblog='$weblog'"); if($db->num_rows($checkstatic1)==0){ $db->query("INSERT INTO blogonline (w_id,weblog,ip,date,timestamp,useronline,username)VALUES('$w_id','$weblog','$ip','$todatedate','$timestamp','$useronlines','$useronline')"); } $db->free($checkstatic1); $db->query("DELETE FROM blogonline WHERE timestamp<$timeout and weblog = '$weblog'"); //end static //new static $newstatic =$db->super_query("SELECT * FROM newstatic where weblog = '$weblog'"); $today=$newstatic["today"]; $lastday=$newstatic["lastday"]; $total=$newstatic["total"]; $todayhit=$newstatic["todayhit"]; $lastdayhit=$newstatic["lastdayhit"]; $months=$newstatic["month"]; $years=$newstatic["year"]; $monthcal=$newstatic["monthcal"]; $yearcal=$newstatic["yearcal"]; $date=$newstatic["date"]; if($date != "$todatedate"){ $db->query("UPDATE newstatic SET lastday='$today' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET lastdayhit='$todayhit' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET todayhit='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET date='$todatedate' WHERE weblog = '$weblog'"); } $db->query("UPDATE newstatic SET total=total+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today=today+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET month=month+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET year=year+1 WHERE weblog = '$weblog'"); if($monthcal!="$month"){ $db->query("UPDATE newstatic SET month='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET monthcal='$month' WHERE weblog = '$weblog'"); } if($yearcal!="$year"){ $db->query("UPDATE newstatic SET year='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET yearcal='$year' WHERE weblog = '$weblog'"); } $db->query("INSERT INTO static (w_id,weblog,ip,date,year,month,referer,refereract)VALUES('$w_id','$weblog','$ip','$todatedate','$year','$month','$referer','$refereract')"); //finish static //end new static include('More.php'); } elseif(isset($_GET['Tags'])){ //static $add_time = time(); $todatedate = date("Y-m-d", $add_time); $year = jgmdate("Y", $add_time); $month = jgmdate("m", $add_time); $timestamp=time(); $timeoutseconds= "300"; $timeout=$timestamp-$timeoutseconds; if(isset($_SERVER['HTTP_REFERER'])){ @$referer= htmlspecialchars($_SERVER['HTTP_REFERER']); @$referer= addslashes($referer); $refereract='1'; } else { $referer=''; $refereract='0'; } if(isset($_SESSION["$s2"])){ $useronline=$_SESSION["$s2"]; $useronlines='1'; } else { $useronline=''; $useronlines='0'; } $checkstatic1 = $db->query("SELECT * FROM blogonline WHERE ip='$ip' and weblog='$weblog'"); if($db->num_rows($checkstatic1)==0){ $db->query("INSERT INTO blogonline (w_id,weblog,ip,date,timestamp,useronline,username)VALUES('$w_id','$weblog','$ip','$todatedate','$timestamp','$useronlines','$useronline')"); } $db->free($checkstatic1); $db->query("DELETE FROM blogonline WHERE timestamp<$timeout and weblog = '$weblog'"); //end static //new static //result static blog $newstatic =$db->super_query("SELECT * FROM newstatic where weblog = '$weblog'"); $today=$newstatic["today"]; $lastday=$newstatic["lastday"]; $total=$newstatic["total"]; $todayhit=$newstatic["todayhit"]; $lastdayhit=$newstatic["lastdayhit"]; $months=$newstatic["month"]; $years=$newstatic["year"]; $monthcal=$newstatic["monthcal"]; $yearcal=$newstatic["yearcal"]; $date=$newstatic["date"]; if($date != "$todatedate"){ $db->query("UPDATE newstatic SET lastday='$today' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET lastdayhit='$todayhit' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET todayhit='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET date='$todatedate' WHERE weblog = '$weblog'"); } $db->query("UPDATE newstatic SET total=total+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today=today+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET month=month+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET year=year+1 WHERE weblog = '$weblog'"); if($monthcal!="$month"){ $db->query("UPDATE newstatic SET month='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET monthcal='$month' WHERE weblog = '$weblog'"); } if($yearcal!="$year"){ $db->query("UPDATE newstatic SET year='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET yearcal='$year' WHERE weblog = '$weblog'"); } $db->query("INSERT INTO static (w_id,weblog,ip,date,year,month,referer,refereract)VALUES('$w_id','$weblog','$ip','$todatedate','$year','$month','$referer','$refereract')"); //finish static //end new static include('Tag.php'); } elseif(isset($_GET['Search'])){ //static $add_time = time(); $todatedate = date("Y-m-d", $add_time); $year = jgmdate("Y", $add_time); $month = jgmdate("m", $add_time); $timestamp=time(); $timeoutseconds= "300"; $timeout=$timestamp-$timeoutseconds; if(isset($_SERVER['HTTP_REFERER'])){ @$referer= htmlspecialchars($_SERVER['HTTP_REFERER']); @$referer= addslashes($referer); $refereract='1'; } else { $referer=''; $refereract='0'; } if(isset($_SESSION["$s2"])){ $useronline=$_SESSION["$s2"]; $useronlines='1'; } else { $useronline=''; $useronlines='0'; } $checkstatic1 = $db->query("SELECT * FROM blogonline WHERE ip='$ip' and weblog='$weblog'"); if($db->num_rows($checkstatic1)==0){ $db->query("INSERT INTO blogonline (w_id,weblog,ip,date,timestamp,useronline,username)VALUES('$w_id','$weblog','$ip','$todatedate','$timestamp','$useronlines','$useronline')"); } $db->free($checkstatic1); $db->query("DELETE FROM blogonline WHERE timestamp<$timeout and weblog = '$weblog'"); //end static //new static //result static blog $newstatic =$db->super_query("SELECT * FROM newstatic where weblog = '$weblog'"); $today=$newstatic["today"]; $lastday=$newstatic["lastday"]; $total=$newstatic["total"]; $todayhit=$newstatic["todayhit"]; $lastdayhit=$newstatic["lastdayhit"]; $months=$newstatic["month"]; $years=$newstatic["year"]; $monthcal=$newstatic["monthcal"]; $yearcal=$newstatic["yearcal"]; $date=$newstatic["date"]; if($date != "$todatedate"){ $db->query("UPDATE newstatic SET lastday='$today' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET lastdayhit='$todayhit' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET todayhit='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET date='$todatedate' WHERE weblog = '$weblog'"); } $db->query("UPDATE newstatic SET total=total+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today=today+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET month=month+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET year=year+1 WHERE weblog = '$weblog'"); if($monthcal!="$month"){ $db->query("UPDATE newstatic SET month='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET monthcal='$month' WHERE weblog = '$weblog'"); } if($yearcal!="$year"){ $db->query("UPDATE newstatic SET year='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET yearcal='$year' WHERE weblog = '$weblog'"); } $db->query("INSERT INTO static (w_id,weblog,ip,date,year,month,referer,refereract)VALUES('$w_id','$weblog','$ip','$todatedate','$year','$month','$referer','$refereract')"); //finish static //end new static include('Search.php'); } else{ //static $add_time = time(); $todatedate = date("Y-m-d", $add_time); $year = jgmdate("Y", $add_time); $month = jgmdate("m", $add_time); $timestamp=time(); $timeoutseconds= "300"; $timeout=$timestamp-$timeoutseconds; if(isset($_SERVER['HTTP_REFERER'])){ @$referer= htmlspecialchars($_SERVER['HTTP_REFERER']); @$referer= addslashes($referer); $refereract='1'; } else { $referer=''; $refereract='0'; } if(isset($_SESSION["$s2"])){ $useronline=$_SESSION["$s2"]; $useronlines='1'; } else { $useronline=''; $useronlines='0'; } $checkstatic1 = $db->query("SELECT * FROM blogonline WHERE ip='$ip' and weblog='$weblog'"); if($db->num_rows($checkstatic1)==0){ $db->query("INSERT INTO blogonline (w_id,weblog,ip,date,timestamp,useronline,username)VALUES('$w_id','$weblog','$ip','$todatedate','$timestamp','$useronlines','$useronline')"); } $db->free($checkstatic1); $db->query("DELETE FROM blogonline WHERE timestamp<$timeout and weblog = '$weblog'"); //end static //new static //result static blog $newstatic =$db->super_query("SELECT * FROM newstatic where weblog = '$weblog'"); $today=$newstatic["today"]; $lastday=$newstatic["lastday"]; $total=$newstatic["total"]; $todayhit=$newstatic["todayhit"]; $lastdayhit=$newstatic["lastdayhit"]; $months=$newstatic["month"]; $years=$newstatic["year"]; $monthcal=$newstatic["monthcal"]; $yearcal=$newstatic["yearcal"]; $date=$newstatic["date"]; if($date != "$todatedate"){ $db->query("UPDATE newstatic SET lastday='$today' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET lastdayhit='$todayhit' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET todayhit='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET date='$todatedate' WHERE weblog = '$weblog'"); } $db->query("UPDATE newstatic SET total=total+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET today=today+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET month=month+1 WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET year=year+1 WHERE weblog = '$weblog'"); if($monthcal!="$month"){ $db->query("UPDATE newstatic SET month='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET monthcal='$month' WHERE weblog = '$weblog'"); } if($yearcal!="$year"){ $db->query("UPDATE newstatic SET year='0' WHERE weblog = '$weblog'"); $db->query("UPDATE newstatic SET yearcal='$year' WHERE weblog = '$weblog'"); } $db->query("INSERT INTO static (w_id,weblog,ip,date,year,month,referer,refereract)VALUES('$w_id','$weblog','$ip','$todatedate','$year','$month','$referer','$refereract')"); //finish static //end new static include('maining.php'); } }}}}}}}}}}}}} // INPUT [-BlogTitle-] , [-BlogDescription-],[-BlogAbout-],[-BlogPhoto-],[-BlogPhotoLink-] $search_array1 = Array("[-Title-]","[-BlogTitle-]", "[-BlogDescription-]","[-Blogid-]","[-BlogAdress-]","[-BlogEmail-]","[-Profile-]","[-Linkbox-]","[-Signup-]","[-Contact-]","[-RssAdress-]"); $replace_array1 = Array("$txttitle","$txttitle", "$txtdescription","$weblog","$domain","$txtemail","/Profile","/Linkbox","/Register","/Contact","/Rss.xml"); $template = str_replace($search_array1,$replace_array1, $template); echo "$template"; //end blog //java down $javadown = $db->super_query("SELECT code FROM downjava where weblog = '$weblog'"); $search_array5 = Array("<", ">", "\"","'","&"); $replace_array5 = Array("<", ">", ""","'","&"); $javadown['code'] = str_replace($replace_array5,$search_array5, $javadown['code']); echo $javadown["code"]; include('adsprocess.php'); //finish $db->free($checkip); } //end for ip }//end for block blog $db->free($checkabuse); }//end for block ADress $db->free($checkblog); } // end check blog $db->free($checkblocked); }//end for block site }// end for temp & blog $db->close(); ?>