Update 1.2.2p3

HCN 함수 수정
This commit is contained in:
wonipapa 2017-09-18 09:37:50 +09:00 committed by GitHub
parent 49a4b1dc58
commit 6004ead922

View File

@ -729,7 +729,7 @@ function GetEPGFromHcn($ChannelInfo) {
libxml_use_internal_errors(True); libxml_use_internal_errors(True);
if($dom->loadHTML($response)): if($dom->loadHTML($response)):
$xpath = new DomXPath($dom); $xpath = new DomXPath($dom);
$query = "//li"; $query = "//li[@class!='noData']";
$rows = $xpath->query($query); $rows = $xpath->query($query);
foreach($rows as $row) : foreach($rows as $row) :
$startTime = $endTime = $programName = $subprogramName = $desc = $actors = $producers = $category = $episode = ""; $startTime = $endTime = $programName = $subprogramName = $desc = $actors = $producers = $category = $episode = "";
@ -738,8 +738,6 @@ function GetEPGFromHcn($ChannelInfo) {
$startTime = trim($xpath->query("span[@class='progTime']", $row)->item(0)->nodeValue) ?: ""; $startTime = trim($xpath->query("span[@class='progTime']", $row)->item(0)->nodeValue) ?: "";
$startTime = date("YmdHis", strtotime($day." ".$startTime)); $startTime = date("YmdHis", strtotime($day." ".$startTime));
$programName = trim($xpath->query("span[@class='progTitle']", $row)->item(0)->nodeValue) ?: ""; $programName = trim($xpath->query("span[@class='progTitle']", $row)->item(0)->nodeValue) ?: "";
//$category = trim($cells->item(2)->nodeValue) ?: "";
//$category = preg_replace('/\(.*\)/', '', $category);
$images = $row->getElementsByTagName('img'); $images = $row->getElementsByTagName('img');
foreach($images as $image): foreach($images as $image):
preg_match('/re\.png/', $image->getAttribute('src'), $rebroad); preg_match('/re\.png/', $image->getAttribute('src'), $rebroad);