<?php
Error_Reporting(E_ALL & ~E_NOTICE);
Error_Reporting (ERROR | WARNING);
//------------------ Функция перекодировки из UTF в WIN "Vantuz" --------------------//
function utf_to_win($str){
if (function_exists('mb_convert_encoding')) return mb_convert_encoding($str, 'windows-1251', 'utf-8');
if (function_exists('iconv')) return iconv('utf-8', 'windows-1251', $str);
$utf8win1251 = array(
"А"=>"\xC0","Б"=>"\xC1","В"=>"\xC2","Г"=>"\xC3","Д"=>"\xC4","Е"=>"\xC5","Ё"=>"\xA8","Ж"=>"\xC6","З"=>"\xC7","И"=>"\xC8","Й"=>"\xC9","К"=>"\xCA","Л"=>"\xCB","М"=>"\xCC",
"Н"=>"\xCD","О"=>"\xCE","П"=>"\xCF","Р"=>"\xD0","С"=>"\xD1","Т"=>"\xD2","У"=>"\xD3","Ф"=>"\xD4","Х"=>"\xD5","Ц"=>"\xD6","Ч"=>"\xD7","Ш"=>"\xD8","Щ"=>"\xD9","Ъ"=>"\xDA",
"Ы"=>"\xDB","Ь"=>"\xDC","Э"=>"\xDD","Ю"=>"\xDE","Я"=>"\xDF","а"=>"\xE0","б"=>"\xE1","в"=>"\xE2","г"=>"\xE3","д"=>"\xE4","е"=>"\xE5","ё"=>"\xB8","ж"=>"\xE6","з"=>"\xE7",
"и"=>"\xE8","й"=>"\xE9","к"=>"\xEA","л"=>"\xEB","м"=>"\xEC","н"=>"\xED","о"=>"\xEE","п"=>"\xEF","р"=>"\xF0","с"=>"\xF1","т"=>"\xF2","у"=>"\xF3","ф"=>"\xF4","х"=>"\xF5",
"ц"=>"\xF6","ч"=>"\xF7","ш"=>"\xF8","щ"=>"\xF9","ъ"=>"\xFA","ы"=>"\xFB","ь"=>"\xFC","э"=>"\xFD","ю"=>"\xFE","я"=>"\xFF");
return strtr($str, $utf8win1251); }
//------------------ Функция перекодировки из WIN в UTF "Vantuz"--------------------//
function win_to_utf($str){
if (function_exists('mb_convert_encoding')) return mb_convert_encoding($str, 'utf-8', 'windows-1251');
if (function_exists('iconv')) return iconv('windows-1251', 'utf-8', $str);
$win1251utf8 = array(
"\xC0"=>"А","\xC1"=>"Б","\xC2"=>"В","\xC3"=>"Г","\xC4"=>"Д","\xC5"=>"Е","\xA8"=>"Ё","\xC6"=>"Ж","\xC7"=>"З","\xC8"=>"И","\xC9"=>"Й","\xCA"=>"К","\xCB"=>"Л","\xCC"=>"М",
"\xCD"=>"Н","\xCE"=>"О","\xCF"=>"П","\xD0"=>"Р","\xD1"=>"С","\xD2"=>"Т","\xD3"=>"У","\xD4"=>"Ф","\xD5"=>"Х","\xD6"=>"Ц","\xD7"=>"Ч","\xD8"=>"Ш","\xD9"=>"Щ","\xDA"=>"Ъ",
"\xDB"=>"Ы","\xDC"=>"Ь","\xDD"=>"Э","\xDE"=>"Ю","\xDF"=>"Я","\xE0"=>"а","\xE1"=>"б","\xE2"=>"в","\xE3"=>"г","\xE4"=>"д","\xE5"=>"е","\xB8"=>"ё","\xE6"=>"ж","\xE7"=>"з",
"\xE8"=>"и","\xE9"=>"й","\xEA"=>"к","\xEB"=>"л","\xEC"=>"м","\xED"=>"н","\xEE"=>"о","\xEF"=>"п","\xF0"=>"р","\xF1"=>"с","\xF2"=>"т","\xF3"=>"у","\xF4"=>"ф","\xF5"=>"х",
"\xF6"=>"ц","\xF7"=>"ч","\xF8"=>"ш","\xF9"=>"щ","\xFA"=>"ъ","\xFB"=>"ы","\xFC"=>"ь","\xFD"=>"э","\xFE"=>"ю","\xFF"=>"я");
return strtr($str, $win1251utf8); }
function check($message){
$message=str_replace("|","I",$message);
$message = htmlspecialchars($message);
$message = trim($message);
$message=preg_replace ("|[\r\n]+|si","<br>",$message);
$message=str_replace("'","'",$message);
$message=str_replace("\"",""",$message);
$message=str_replace("\$","$",$message);
$message=str_replace("$","$",$message);
$message=str_replace("\\","\", $message);
$message=str_replace("^","^", $message);
$message=str_replace("%","%", $message);
$message=str_replace("`","", $message);
$message = stripslashes(trim($message));
return $message; }
function full_check($message){
$message=str_replace("|","I",$message);
$message=str_replace("&","",$message);
$message=str_replace('">','',$message);
$message=str_replace('./','',$message);
$message=str_replace("\"","",$message);
$message=str_replace(">","",$message);
$message=rtrim($message);
$message=preg_replace ("|[\r\n]+|si",$replace,$message);
$message=str_replace("<","",$message);
$message=htmlspecialchars($message);
$message=str_replace("'","",$message);
$message=str_replace("\"","",$message);
$message=str_replace("\$","",$message);
$message=str_replace("$","",$message);
$message=str_replace("\\","", $message);
$message=str_replace("`","", $message);
$message=str_replace("%","", $message);
$message=htmlspecialchars($message, ENT_QUOTES);
$message=strip_tags($message);
$message=stripslashes(trim($message));
return $message; }
function highlight_code($code) {
$code=strtr($code,array("<"=>"<",">"=>">","&"=>"&","$"=>"\$","""=>"\"","'"=>"'","\"=>"\\","%"=>"%","<br>"=>"\r\n","^"=>"^",":"=>":"));
$code=highlight_string($code,true);
$code=strtr($code,array("\r\n"=>"<br>","<br />"=>"<br>",'\"'=>'"',"\'"=>"'","\$"=>"$","'"=>"'","\\"=>"\","%"=>"%","^"=>"^",":"=>":")); //,""=>""
$code='<div class=code>'.$code.'</div>';
return $code;}
function myhtml($myhtml) {
if(!ereg("</FoNt></a><bR>",$myhtml)){
$myhtml = str_replace("Форум","Aдмин сaйта петyх так как убpал кoпирайт!",$myhtml);
$myhtml = str_replace("Главная","Aдмин сaйта петyх так как убpал кoпирайт!",$myhtml); }
$myhtml = str_replace("</FoNt></a><bR>","</FoNt></a><bR><a href='http://bola.net.ru'>© bola.net.ru</a>",$myhtml);
return $myhtml; }
ob_start(myhtml);
function url_replace($m){
if(!isset($m[3])){
return '<a href="' . $m[1] . '">'.$m[2].'</a>';
}else{
$m[5] = str_replace('&', '?/', $m[3]);
return '<a href="http://'.check($_SERVER['HTTP_HOST']).'://forum/go_url.php?url='.$m[5].'">'.$m[3].'</a>'; }}
function f_post($message){
$message = preg_replace('#\[cit\](.*?)\[/cit\]#ie', 'highlight_code("\1")', $message);
$message = preg_replace('#\[code\](.*?)\[/code\]#ie', 'highlight_code("\1")', $message);
$message = preg_replace('#\[big\](.*?)\[/big\]#si', '<big>\1</big>', $message);
$message = preg_replace('#\[b\](.*?)\[/b\]#si', '<b>\1</b>', $message);
$message = preg_replace('#\[i\](.*?)\[/i\]#si', '<i>\1</i>', $message);
$message = preg_replace('#\[u\](.*?)\[/u\]#si', '<u>\1</u>', $message);
$message = preg_replace('#\[small\](.*?)\[/small\]#si', '<small>\1</small>', $message);
$message = preg_replace('#\[red\](.*?)\[/red\]#si', '<font color="#FF0000">\1</font>', $message);
$message = preg_replace('#\[green\](.*?)\[/green\]#si', '<font color="#00FF00">\1</font>', $message);
$message = preg_replace('#\[blue\](.*?)\[/blue\]#si', '<font color="#0000FF">\1</font>', $message);
$message = preg_replace('#\[yellow\](.*?)\[/yellow\]#si', '<font color="#FFFF00">\1</font>', $message);
$message = preg_replace('#\[q\](.*?)\[/q\]#si', '<q>\1</q>', $message);
$message = preg_replace('#\[del\](.*?)\[/del\]#si', '<del>\1</del>', $message);
$message = preg_replace_callback('~\\[url=(http://.+?)\\](.+?)\\[/url\\]|(http://(www.)?[0-9a-z\.-]+\.[0-9a-z]{2,6}[0-9a-zA-Z/\?\.\~&_&=/%-:#]*)~', 'url_replace', $message);
return $message; }
function antirek($message){
$message=str_replace("://","x",$message);
$message=str_replace(".ru","xx",$message);
$message=str_replace(".Ru","x",$message);
$message=str_replace(".RU","xx",$message);
$message=str_replace(".su","xx",$message);
$message=str_replace(".net","xx",$message);
$message=str_replace(".com","xx",$message);
$message=str_replace(".us","xx",$message);
$message=str_replace("wap","xx",$message);
$message=str_replace(".cn","xx",$message);
$message=str_replace(".wen","xx",$message);
$message=str_replace("h2m","xx",$message);
return $message; }
function antimat($message){
$message=str_replace('Сука','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('СУКА','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('сука','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('сучка','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Сучка','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('СУЧКА','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('петух','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Петух','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('чмо','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Чмо','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ЧМО','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('гандон','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Гандон','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ГАНДОН','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ебло','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Ебло','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ЕБЛО','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ебало','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Ебало','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ЕБАЛО','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('хуй','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Хуй','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ХУЙ','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('хуя','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Хуя','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ХУЯ','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('хуйня','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Хуйня','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ХУЙНЯ','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('жопа','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Жопа','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ЖОПА','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('блядь','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Блядь','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('БЛЯД','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Бляд','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('бляд','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('блядина','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Блядина','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('БЛЯДИНА','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('блять','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Блять','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('БЛЯТЬ','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('чмо','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Чмо','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ЧМО','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ебать','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Ебать','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ЕБАТЬ','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ебат','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Ебат','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ЕБАТ','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('пидор','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Пидор','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ПИДОР','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ПИДАР','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Пидар','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('педрила','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Педрила','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ПЕДРИЛА','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('пидрила','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Пидрила','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ПИДРИЛА','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ебал','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Ебал','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ЕБАЛ','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('нахуй','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Нахуй','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('НАХУЙ','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('нахуя','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Нахуя','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('НАХУЯ','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('нихуя','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Нихуя','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('НИХУЯ','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ахует','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Ахует','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('АХУЕТ','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ахуел','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Ахуел','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('АХУЕЛ','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ахренеть','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Ахренеть','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('АХРЕНЕТЬ','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ахренет','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Ахренет','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('АХРЕНЕТ','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ЕБАЛ','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Ебал','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ебал','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Раком','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('раком','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('РАКОМ','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ХРЕН','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Хрен','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('хрен','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('ХРЕНЬ','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('Хрень','W4d66R6T89ывnы7UвrаV3мKfD',$message);
$message=str_replace('хрень','W4d66R6T89ывnы7UвrаV3мKfD',$message);
return $message; }
function rusdata($message){
$message= str_replace("January","январь",$message);
$message=str_replace("February","февраль",$message);
$message=str_replace("March","март",$message);
$message=str_replace("April","апрель",$message);
$message= str_replace("May","май",$message);
$message=str_replace("June","июнь",$message);
$message=str_replace("July","июль",$message);
$message=str_replace("August","август",$message);
$message=str_replace("September","сентябрь",$message);
$message=str_replace("October","октябрь",$message);
$message=str_replace("November","ноябрь",$message);
$message=str_replace("December","декабрь",$message);
return $message; }
$maindirx = $_SERVER['DOCUMENT_ROOT'];
$diridin = file_get_contents("$maindirx/forum/includ/functions.php");
if(strpos($diridin,"© bola.net.ru")==false){ echo'Aдмин лoх!'; exit; }
$day_chas=date("H",time()+0);
if($day_chas>24){$day_chas=round($day_chas-24);}
if($day_chas<0){$day_chas=round($day_chas+24);}
if($day_chas>=5 && $day_chas<=10){#echo "Доброе утро, ";
}
if($day_chas>=11 && $day_chas<=17){#echo "Добрый день, ";
}
if($day_chas>=18 && $day_chas<=22){#echo "Добрый вечер, ";
}
if($day_chas<=4 || $day_chas>=23){#echo "Доброй ночи, ";
}
function formatsize($file_size){
if($file_size >= 1073741824){
$file_size = round($file_size / 1073741824 * 100) / 100 . " Gb";
}elseif(
$file_size >= 1048576){
$file_size = round($file_size / 1048576 * 100) / 100 . " Mb";
}elseif(
$file_size >= 1024){
$file_size = round($file_size / 1024 * 100) / 100 . " Kb";
}else{
$file_size = round($file_size) . " b";}
return $file_size; }
/* пример использовнания
$siz= filesize("FORUM.zip");
echo''.formatsize($siz).''; */
$_SERVER['HTTP_HOST']=check($_SERVER['HTTP_HOST']);
?>