Welcome to World of IPTV

Join us now to get access to all our features. Once registered and logged in, you will be able to create topics, post replies to existing threads, give reputation to your fellow members, get your own private messenger, and so, so much more. It's also quick and totally free, so what are you waiting for?

Forum Rules

Our Rules: Read to avoid getting banned!

Advertising

Introduce Yourself to the World with Us!

Resource Database

Find the newest resources around IPTV!

Account upgrade

Upgrade your account to unlock more benefits!

Request M3u playlist scanner

Themob4you

Basic Member
Basic Member
Joined
May 19, 2021
Messages
85
Reaction score
150
Points
44
Location
arownd worldofiptv :)
Hello! anyone knows a tool for m3u playlist checker ? scanner ! to put m3u and run it an to tell me streams wich are offline , how can easy do that ?
 
This might work..

Code:
<?php
$url = "http://xxxx.site/get.php?username=xxx&password=xxx&type=m3u_plus&output=ts";
$options = array(
    'http'=>array(
      'method'=>"GET",
      'header'=>"Accept-language: en\r\n" .
                "User-Agent: Mozilla/5.0 \r\n"
    )
);
$context = stream_context_create($options);

#$data =  file_get_contents($url);
if(!file_exists("/tmp/testplaylist")) {
    $data = file_get_contents($url, false, $context);
    file_put_contents("/tmp/testplaylist", $data);
    unset($data);
}
$pls = fopen("/tmp/testplaylist", "rb");
if (FALSE === $pls) {
    exit("Failed to open stream to URL");
}
$contents = '';
$i = 0;
$down = array();
while (!feof($pls)) {
    $line = trim(fgets($pls));
    if($line[0] != "#") {
        if($handle = @fopen($line, "r")) {
            $contents = fread($handle, 1000);
            fclose($handle);
            file_put_contents("/tmp/c", $contents);
#            echo mime_content_type("/tmp/c").PHP_EOL;
            @unlink("/tmp/c");
        }
        else {
            echo PHP_EOL . $line ." Down".PHP_EOL;
            $down[] = $line;
        }
        echo $i++ ." ";
    }
}
fclose($pls);
print_r($down);
 
shape1
shape2
shape3
shape4
shape5
shape6
Back
Top