Вход Регистрация
Файл: link/janr.php
Строк: 27
<?php
require_once '../config.php';
$url = 'http://faptv.net/genre/';
$cachtime = 86400;
$url2 = md5($url);
$cachfile = 'cache/pages/'.$url2.'';
##############################
if(file_exists($cachfile) AND ((time() - filemtime($cachfile)) < $cachtime))
{ 
$out = file_get_contents($cachfile); }else{
require_once 
'../curl.php';
##############################
preg_match('|<title>(.*)</title>|Us', $res, $titless);
$titless[1]=str_replace('FapTV.net', ''.copyR.'', $titless[1]);

preg_match_all('|<div class="tags">(.*)</div>|Us', $res, $down);

  
$down[1]=str_replace('class="tag"', '', $down[1]);
  
$down[1]=str_replace('/genre/', ''.HOME.'janr/', $down[1]);
if (!empty(
$down[1][0])){
$count = count($down[1]);
$i = 0;
while (
$i < $count){     
$out .= '
'
.DIVfon.''.$down[1][$i].'</div>';
$i++;
}}
else
{ 
$out .= 'Ошибка'; }
#######################
        
##################################
if(CACH == 1) {
$file = fopen($cachfile,'w'); 
fputs($file, $out); 
fclose($file);
}}
##################################
$titles = $titless[1];
include(
'../system/head.php');
include(
'../system/bar.php');
##############################
echo $out;
include(
'../system/foot.php');
?>
Онлайн: 1
Реклама