Commit 4412bae2 authored by Nico Schallehn's avatar Nico Schallehn

coverdownload für serien angepasst (nur konvertieren)

parent 9466bce3
......@@ -1320,7 +1320,7 @@ class Media {
}
echo $this->Console->getColoredString("Coverdownload > Serien und Staffeln", "black", "light_gray") .PHP_EOL;
$Query = "SELECT series_nr FROM Serien GROUP BY series_nr;";
/*
$result = $mysqli->query($Query);
if($mysqli->error != ""){ echo "Mysql-Fehler: ".$mysqli->error.PHP_EOL; return false;}
......@@ -1338,7 +1338,8 @@ class Media {
}
while ($Film = $result->fetch_assoc()){
if(!file_exists($this->config["CoverDir"]."Serien/full/".$Film["series_nr"].".jpg")){
echo "Lade Cover (".$Film["series_nr"].") von Markus ....";
echo "kein cover für (".$Film["series_nr"].") gefunden!".PHP_EOL;
/*echo "Lade Cover (".$Film["series_nr"].") von Markus ....";
$url = "http://mediadb.ddns.net/cover/Serien/full/".$Film["series_nr"].".jpg";//1479358
//echo $url."<>wget ".$url." -O ".$this->config["CoverDir"].$Film["imdbID"].".jpg";
shell_exec("wget ".$url." -O ".$this->config["CoverDir"]."Serien/full/".$Film["series_nr"].".jpg > /dev/null 2>&1"); //");//
......@@ -1349,7 +1350,7 @@ class Media {
shell_exec("rm ".$this->config["CoverDir"]."Serien/full/".$Film["series_nr"].".jpg");
echo "fail".PHP_EOL;
$counterNotFound++;
}
}*/
}else{ echo "Cover für series_nr: ".$Film["series_nr"]." existiert bereits!".PHP_EOL;}
if(file_exists($this->config["CoverDir"]."Serien/full/".$Film["series_nr"].".jpg") AND !file_exists($this->config["CoverDir"]."Serien/low/".$Film["series_nr"].".jpg")){
shell_exec("convert ".$this->config["CoverDir"]."Serien/full/".$Film["series_nr"].".jpg".
......@@ -1364,7 +1365,8 @@ class Media {
while ($Film2 = $result2->fetch_assoc()){
if(!file_exists($this->config["CoverDir"]."Staffeln/full/".$Film2["season_nr"].".jpg")){
echo " Lade Cover (".$Film2["season_nr"].") von Markus ....";
echo " kein cover für (".$Film2["season_nr"].") gefunden";
/*echo " Lade Cover (".$Film2["season_nr"].") von Markus ....";
$url = "http://mediadb.ddns.net/cover/Staffeln/full/".$Film2["season_nr"].".jpg";
//echo $url;
shell_exec("wget ".$url." -O ".$this->config["CoverDir"]."Staffeln/full/".$Film2["season_nr"].".jpg > /dev/null 2>&1"); //");//
......@@ -1375,7 +1377,7 @@ class Media {
shell_exec("rm ".$this->config["CoverDir"]."Staffeln/full/".$Film2["season_nr"].".jpg");
echo "fail".PHP_EOL;
$counterNotFound++;
}
}*/
}else{ echo " Cover für season_nr: ".$Film2["season_nr"]." existiert bereits!".PHP_EOL;}
if(file_exists($this->config["CoverDir"]."Staffeln/full/".$Film2["season_nr"].".jpg") AND !file_exists($this->config["CoverDir"]."Staffeln/low/".$Film2["season_nr"].".jpg")){
shell_exec("convert ".$this->config["CoverDir"]."Staffeln/full/".$Film2["season_nr"].".jpg".
......@@ -1386,7 +1388,7 @@ class Media {
$this->config["CoverDir"]."Staffeln/high/".$Film2["season_nr"].".jpg");
}
}
}*/
}
echo $this->Console->getColoredString("Coverdownload > Upload auf FTP Server", "black", "light_gray") .PHP_EOL;
$SFTP_SERVER="192.168.0.32";
$SFTP_USER="nico";
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment