���� JFIF �� � ( %"1"%)+...383,7(-.-
![]() Server : Apache/2.4.6 (CentOS) OpenSSL/1.0.2k-fips PHP/7.4.20 System : Linux st2.domain.com 3.10.0-1127.10.1.el7.x86_64 #1 SMP Wed Jun 3 14:28:03 UTC 2020 x86_64 User : apache ( 48) PHP Version : 7.4.20 Disable Function : NONE Directory : /var/www/html/img.123vid.top/ |
<?php function str_encode($data,$pwd) { $x = 0; $a = 0; $j = 0; $Zcrypt = ''; $pwd_length = strlen($pwd); for ($i = 0; $i < 255; $i++) { $key[$i] = ord(substr($pwd, ($i % $pwd_length)+1, 1)); $counter[$i] = $i; } for ($i = 0; $i < 255; $i++) { $x = ($x + $counter[$i] + $key[$i]) % 256; $temp_swap = $counter[$i]; $counter[$i] = $counter[$x]; $counter[$x] = $temp_swap; } for ($i = 0; $i < strlen($data); $i++) { $a = ($a + 1) % 256; $j = ($j + $counter[$a]) % 256; $temp = $counter[$a]; $counter[$a] = $counter[$j]; $counter[$j] = $temp; $k = $counter[(($counter[$a] + $counter[$j]) % 256)]; $Zcipher = ord(substr($data, $i, 1)) ^ $k; $Zcrypt .= chr($Zcipher); } return $Zcrypt; } function format_string($str2){ $str = bodau($str2); $str = preg_replace('/^[^\p{L}\p{Nd}]+/',' ', $str); $str = trim($str); $str = preg_replace('/\s+/', ' ', $str); $str = preg_replace('/\s+/', '-', $str); return empty($str)?str_replace(' ','-',$str2):strtolower($str); } function bodau($str) { $chuCoDau=array("à","á","ạ","ả","ã","â","ầ","ấ","ậ","ẩ","ẫ","ă", "ằ","ắ","ặ","ẳ","ẵ","è","é","ẹ","ẻ","ẽ","ê","ề" ,"ế","ệ","ể","ễ", "ì","í","ị","ỉ","ĩ", "ò","ó","ọ","ỏ","õ","ô","ồ","ố","ộ","ổ","ỗ","ơ" ,"ờ","ớ","ợ","ở","ỡ", "ù","ú","ụ","ủ","ũ","ư","ừ","ứ","ự","ử","ữ", "ỳ","ý","ỵ","ỷ","ỹ", "đ", "À","Á","Ạ","Ả","Ã","Â","Ầ","Ấ","Ậ","Ẩ","Ẫ","Ă" ,"Ằ","Ắ","Ặ","Ẳ","Ẵ", "È","É","Ẹ","Ẻ","Ẽ","Ê","Ề","Ế","Ệ","Ể","Ễ", "Ì","Í","Ị","Ỉ","Ĩ", "Ò","Ó","Ọ","Ỏ","Õ","Ô","Ồ","Ố","Ộ","Ổ","Ỗ","Ơ" ,"Ờ","Ớ","Ợ","Ở","Ỡ", "Ù","Ú","Ụ","Ủ","Ũ","Ư","Ừ","Ứ","Ự","Ử","Ữ", "Ỳ","Ý","Ỵ","Ỷ","Ỹ", "Đ","?","&",",","/",".","!","@","#","$","%","//",":","\"","\\","'","$","^","(",")","\"","=","_","__","\"","“","”","-"," - ","|","[","]"); $chuKoDau=array("a","a","a","a","a","a","a","a","a","a","a" ,"a","a","a","a","a","a", "e","e","e","e","e","e","e","e","e","e","e", "i","i","i","i","i", "o","o","o","o","o","o","o","o","o","o","o","o" ,"o","o","o","o","o", "u","u","u","u","u","u","u","u","u","u","u", "y","y","y","y","y", "d", "A","A","A","A","A","A","A","A","A","A","A","A" ,"A","A","A","A","A", "E","E","E","E","E","E","E","E","E","E","E", "I","I","I","I","I", "O","O","O","O","O","O","O","O","O","O","O","O" ,"O","O","O","O","O", "U","U","U","U","U","U","U","U","U","U","U", "Y","Y","Y","Y","Y", "D","","","","","","","","","","","","","","","","","","","","","","","","","","","",'-','','',''); $outstr = str_replace($chuCoDau,$chuKoDau,$str); $outstr = strtolower(trim($outstr)); return $outstr; } function curl_func($url) { $ch = curl_init(); $head[] = 'Host: m.youtube.com'; $head[] = 'User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:77.0) Gecko/20100101 Firefox/77.0'; $head[] = 'Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8'; $head[] = 'Accept-Language: en-US,en;q=0.5'; $head[] = 'Accept-Encoding: gzip'; $head[] = 'Connection: keep-alive'; $head[] = 'Cookie: VISITOR_INFO1_LIVE=fQJoDmD2uIM; _ga=GA1.2.132832653.1582794066; PREF=app=m; CONSENT=YES+VN.vi+20170312-18-0; YSC=f7ClEVxjn-o; GPS=1'; $head[] = 'Upgrade-Insecure-Requests: 1'; $head[] = 'Pragma: no-cache'; $head[] = 'Cache-Control: no-cache'; curl_setopt($ch, CURLOPT_USERAGENT, 'Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:77.0) Gecko/20100101 Firefox/77.0'); curl_setopt($ch, CURLOPT_HTTPHEADER, $head); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_REFERER, 'https://m.youtube.com'); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); curl_setopt($ch, CURLOPT_COOKIEJAR, 'cookies-m-youtube-com-search.txt'); curl_setopt($ch, CURLOPT_COOKIEFILE, 'cookies-m-youtube-com-search.txt'); curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, FALSE); curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, FALSE); curl_setopt($ch, CURLOPT_TIMEOUT, 60); curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 60); curl_setopt($ch, CURLOPT_FOLLOWLOCATION, TRUE); curl_setopt($ch,CURLOPT_ENCODING , "gzip"); $page = curl_exec($ch); curl_close($ch); return $page; } include 'simple_html_dom.php'; $keyword = $_GET['kw']; $vq = str_replace(array(' ','%20','<','>'),array('+','+','',''),$keyword); $url_get = 'https://m.youtube.com/results?search_query='.$vq; $ref = base64_encode($url_get); $content2 = curl_func($url_get); $html = str_get_html($content2); $content2 = $html->find('div#initial-data',0)->innertext; $content2 = str_replace(array('<!--','-->'),array('',''),$content2); $data = json_decode(trim($content2),true); $detail['ref'] = $ref; $detail['total'] = $data['estimatedResults']; $detail['avatar'] = $data['contents']['sectionListRenderer']['contents']['0']['itemSectionRenderer']['contents']['0']['compactVideoRenderer']['channelThumbnail']['thumbnails']['0']['url']; $detail['next_token'] = $data['contents']['sectionListRenderer']['contents']['0']['itemSectionRenderer']['continuations']['0']['nextContinuationData']['continuation']; $detail['video_1_title'] = $data['contents']['sectionListRenderer']['contents']['0']['itemSectionRenderer']['contents']['0']['compactVideoRenderer']['title']['runs']['0']['text']; $channel_url = $data['contents']['sectionListRenderer']['contents']['0']['itemSectionRenderer']['contents']['0']['compactVideoRenderer']['longBylineText']['runs']['0']['navigationEndpoint']['commandMetadata']['webCommandMetadata']['url']; $channel_name = $data['contents']['sectionListRenderer']['contents']['0']['itemSectionRenderer']['contents']['0']['compactVideoRenderer']['longBylineText']['runs']['0']['text']; $channel_fname = format_string($channel_name); $detail['chanel_id'] = bin2hex(str_encode(basename($channel_url), 'ngocgiac')); $detail['video_1_des'] = $detail['video_1_title'].' by <a href="channel/'.$detail['chanel_id'].'/'.$channel_fname.'/">'.$channel_name.'</a> '.$data['contents']['sectionListRenderer']['contents']['0']['itemSectionRenderer']['contents']['0']['compactVideoRenderer']['publishedTimeText']['runs']['0']['text'].' '.$data['contents']['sectionListRenderer']['contents']['0']['itemSectionRenderer']['contents']['0']['compactVideoRenderer']['viewCountText']['runs']['0']['text'].' '.$data['contents']['sectionListRenderer']['contents']['0']['itemSectionRenderer']['contents']['0']['compactVideoRenderer']['lengthText']['accessibility']['accessibilityData']['label']; $detail['video_1_duration'] = $data['contents']['sectionListRenderer']['contents']['0']['itemSectionRenderer']['contents']['0']['compactVideoRenderer']['lengthText']['runs']['0']['text']; $detail['videos'] = array(); $i=0; foreach($data['contents']['sectionListRenderer']['contents']['0']['itemSectionRenderer']['contents'] as $key=>$val){ if(!empty($val['compactVideoRenderer']['title']['runs']['0']['text']) && !empty($val['compactVideoRenderer']['videoId'])) { $detail['videos'][$i]['title'] = $val['compactVideoRenderer']['title']['runs']['0']['text']; $detail['videos'][$i]['ftitle'] = format_string($detail['videos'][$i]['title']); $detail['videos'][$i]['id'] = $val['compactVideoRenderer']['videoId']; $detail['videos'][$i]['id_encode'] = bin2hex(str_encode($detail['videos'][$i]['id'], 'ngocgiac')); $detail['videos'][$i]['img'] = '//i.ytimg.com/vi/' . $detail['videos'][$i]['id'] . '/mqdefault.jpg'; $detail['videos'][$i]['duration'] = $val['compactVideoRenderer']['lengthText']['runs']['0']['text']; $i++; } } echo json_encode($detail); exit(); print_r($detail); echo '<a href="yt_s2_con.php?token='.$detail['next_token'].'&ref='.$ref.'" target="_blank">continue</a>'; exit(); echo $content2; exit(); ?>