Файловый менеджер - Редактировать - /var/www/fetish/link.php
Назад
<?php require('core/init.php'); ini_set('display_errors', 1); ini_set('display_startup_errors', 1); error_reporting(E_ALL); use \fetish\db; use \fetish\utils; $data = db::query("SELECT * FROM videos WHERE uri = ?",[ $_GET['uri'] ])->first(); if(!$data){ die('Sorry, there was a problem.'); } //Check how old the last scrape was if($data->date_fetched >= date('Y-m-d H:i:s',strtotime('-1 hour')) && !strpos($data->source_video, 'mentor')){ //header('Location: '.$data->source_video, true, 301); header('Location: '.$data->source_video); //die($data->source_video); }else{ $token = utils::get_token('poopeegirls'); //$source = 'https://mentor.dfcdn.net/?v=1&p='.$token.'&f='.$data->source_file.'&e=0&s=0&sig=&b=0'; $x = str_replace('/00/', '/000/', $data->source_file); $source = 'https://mentor.dfcdn.net/?v=1&p='.$token.'&f='.$x.'&e=1633913089&s=-110&sig=wp/og8kD9pQmktu0yLzz7QKEhaj6ax4cNTQSXckcpfY=&b=120'; $ch = curl_init(); $headers = array( 'referer: https://poopeegirls.com/' ); curl_setopt($ch, CURLOPT_URL, $source); curl_setopt($ch, CURLOPT_HTTPHEADER, $headers); curl_setopt($ch, CURLOPT_NOBODY, 1); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); curl_setopt($ch, CURLOPT_HEADER, 1); curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1); // follow redirects curl_setopt($ch, CURLOPT_AUTOREFERER, 1); // set referer on redirect // Timeout in seconds curl_setopt($ch, CURLOPT_TIMEOUT, 20); curl_exec($ch); $target = curl_getinfo($ch, CURLINFO_EFFECTIVE_URL); db::query("UPDATE videos SET date_fetched = ?, source_video = ? WHERE id = ?",[ date('Y-m-d H:i:s'), $target, $data->id ]); //header('Location: '.$target, true, 301); header('Location: '.$target); } ?>
| ver. 1.4 |
Github
|
.
| PHP 7.0.33-0ubuntu0.16.04.16 | Генерация страницы: 0 |
proxy
|
phpinfo
|
Настройка