Skip to content

Commit

Permalink
Merge pull request #3 from WWBN/master
Browse files Browse the repository at this point in the history
up2date
  • Loading branch information
ronaldod authored May 14, 2020
2 parents 8c2cf1e + d655f8c commit 797bbe8
Show file tree
Hide file tree
Showing 73 changed files with 2,478 additions and 1,511 deletions.
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -59,4 +59,6 @@
/iptvsource_one_one.csv
/plugin/DiskUploadQuota/
/plugin/LoginLDAP_DYNA/
/plugin/ZoomMeetingRecorder/
/plugin/ZoomMeetingRecorder/
/plugin/IPTV/
/.scannerwork/
2 changes: 1 addition & 1 deletion .htaccess
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ Options All -Indexes
<filesMatch "\.(ico|pdf|flv|jpg|jpeg|png|gif|swf)$">
Header set Cache-Control "max-age=2592000, public"
</filesMatch>
<filesMatch "\.(css)$">
<filesMatch "\.(woff2|css)$">
Header set Cache-Control "max-age=604800, public"
</filesMatch>
<filesMatch "\.(js)$">
Expand Down
14 changes: 11 additions & 3 deletions feed/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,22 @@
$_POST['rowCount'] = 50;

$showOnlyLoggedUserVideos = false;
$title = "RSS ".$config->getWebSiteTitle();
$title = $config->getWebSiteTitle();
$link = $global['webSiteRootURL'];
$logo = "{$global['webSiteRootURL']}videos/userPhoto/logo.png";
$description = "";

$extraPluginFile = $global['systemRootPath'] . 'plugin/Customize/Objects/ExtraConfig.php';
if (file_exists($extraPluginFile) && AVideoPlugin::isEnabledByName("Customize")) {
require_once $extraPluginFile;
$ec = new ExtraConfig();
$description = $ec->getDescription();
}

if(!empty($_GET['channelName'])){
$user = User::getChannelOwner($_GET['channelName']);
$showOnlyLoggedUserVideos = $user['id'];
$title = "RSS ".User::getNameIdentificationById($user['id']);
$title = User::getNameIdentificationById($user['id']);
$link = User::getChannelLink($user['id']);
$logo = User::getPhoto($user['id']);
}
Expand All @@ -37,7 +45,7 @@
<channel>
<atom:link href="<?php echo $global['webSiteRootURL'].ltrim($_SERVER["REQUEST_URI"],"/"); ?>" rel="self" type="application/rss+xml" />
<title><?php echo $title; ?></title>
<description>Rss Feed</description>
<description><?php echo $description; ?></description>
<link><?php echo $link; ?></link>
<sy:updatePeriod>hourly</sy:updatePeriod>
<sy:updateFrequency>1</sy:updateFrequency>
Expand Down
10 changes: 10 additions & 0 deletions install/checkConfiguration.php
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,16 @@
\$global['ddosSecondTimeout'] = 5;
\$global['strictDDOSprotection'] = 0;
\$global['noDebug'] = 0;
\$global['webSiteRootPath'] = '';
if(empty(\$global['webSiteRootPath'])){
preg_match('/https?:\/\/[^\/]+(.*)/i', \$global['webSiteRootURL'], \$matches);
if(!empty(\$matches[1])){
\$global['webSiteRootPath'] = \$matches[1];
}
}
if(empty(\$global['webSiteRootPath'])){
die('Please configure your webSiteRootPath');
}
\$mysqlHost = '{$_POST['databaseHost']}';
\$mysqlPort = '{$_POST['databasePort']}';
Expand Down
2 changes: 1 addition & 1 deletion install/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@

<link href="../view/bootstrap/bootstrapSelectPicker/css/bootstrap-select.min.css" rel="stylesheet" type="text/css"/>
<link href="../view/js/seetalert/sweetalert.css" rel="stylesheet" type="text/css"/>
<script src="../view/js/jquery-3.3.1.min.js" type="text/javascript"></script>
<script src="../view/js/jquery-3.5.1.min.js" type="text/javascript"></script>
<link href="../view/css/fontawesome-free-5.5.0-web/css/all.min.css" rel="stylesheet" type="text/css"/>
</head>

Expand Down
36 changes: 36 additions & 0 deletions install/makeAdmin.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
<?php
//streamer config
require_once '../videos/configuration.php';

if(!isCommandLineInterface()){
return die('Command Line only');
}
echo "Enter the username or press enter to skip:";
echo "\n";
ob_flush();
$userName = trim(readline(""));

if(!empty($userName)){
$user = new User(0, $userName, false);
if(!empty($user->getBdId())){
$sql = "UPDATE users SET isAdmin = 1, status = 'a' where id = ".$user->getBdId();

$insert_row = sqlDAL::writeSql($sql);
if($insert_row){
echo "Your user {$userName} is admin now";
echo "\n";
die();
}
}else{
echo "User ({$userName}) Not found";
echo "\n";
die();
}
}
echo "Bye";
echo "\n";
die();




76 changes: 76 additions & 0 deletions install/removeRepeatedPlaylists.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
<?php

//streamer config
require_once '../videos/configuration.php';
require_once $global['systemRootPath'] . 'objects/playlist.php';

if (!isCommandLineInterface()) {
return die('Command Line only');
}

$users_ids = array();
$sql = "SELECT distinct(users_id) as users_id FROM playlists ";
$res = sqlDAL::readSql($sql);
$fullData = sqlDAL::fetchAllAssoc($res);
sqlDAL::close($res);
$rows = array();
if ($res != false) {
foreach ($fullData as $key => $row) {
$users_ids[] = $row['users_id'];
}
} else {
die($sql . '\nError : (' . $global['mysqli']->errno . ') ' . $global['mysqli']->error);
}


foreach ($users_ids as $user_id) {
echo "Process user_id = {$user_id}\n";
ob_flush();
$sql = "SELECT * FROM playlists WHERE users_id = {$user_id} AND status = 'favorite' ORDER BY created ";
$res = sqlDAL::readSql($sql);
$fullData = sqlDAL::fetchAllAssoc($res);
sqlDAL::close($res);
$rows = array();
if ($res != false) {
foreach ($fullData as $key => $row) {
if ($key === 0) {
continue;
}

if(!empty(PlayList::getVideosIDFromPlaylistLight($row['id']))){
continue;
}

$sql = "DELETE FROM playlists ";
$sql .= " WHERE id = ?";

echo $sql." = {$row['id']}\n";
ob_flush();
sqlDAL::writeSql($sql, "i", array($row['id']));
}
} else {
die($sql . '\nError : (' . $global['mysqli']->errno . ') ' . $global['mysqli']->error);
}


$sql = "SELECT * FROM playlists WHERE users_id = {$user_id} AND status = 'watch_later' ORDER BY created ";
$res = sqlDAL::readSql($sql);
$fullData = sqlDAL::fetchAllAssoc($res);
sqlDAL::close($res);
$rows = array();
if ($res != false) {
foreach ($fullData as $key => $row) {
if ($key === 0) {
continue;
}
$sql = "DELETE FROM playlists ";
$sql .= " WHERE id = ?";
echo $sql." = {$row['id']}\n";
ob_flush();
sqlDAL::writeSql($sql, "i", array($row['id']));
}
} else {
die($sql . '\nError : (' . $global['mysqli']->errno . ') ' . $global['mysqli']->error);
}

}
45 changes: 23 additions & 22 deletions locale/de.php
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<?php
global $t;

$t['%s ERROR: You must set a ID on config'] = "%s FEHLER: Du mußt eine ID in der config erstellen";
$t['%s ERROR: You must set a KEY on config'] = "%s ERROR: Du mußt einen KEY (Schlüssel) in der config generieren";
$t['%s ERROR: You must set a ID on config'] = "%s FEHLER: Du musst eine ID in der config erstellen";
$t['%s ERROR: You must set a KEY on config'] = "%s ERROR: Du musst einen KEY (Schlüssel) in der config generieren";
$t['(filtered from _MAX_ total entries)'] = "(gefiltert von _MAX_ total Einträgen)";
$t['465 OR 587'] = "465 ODER 587";
$t[': activate to sort column ascending'] = ": aktivieren um aufsteigend zu sortieren";
Expand Down Expand Up @@ -40,7 +40,7 @@
$t['Allow download video'] = "Erlaube Download von Videos";
$t['Alphabetical'] = "Alphabetisch";
$t['Already verified'] = "Bereits bestätigt";
$t['An client error occurred: %s'] = "Ein Fehler im Klienten ist aufgetreten: %s";
$t['An client error occurred: %s'] = "Ein Fehler im Client ist aufgetreten: %s";
$t['Analytics Code'] = "Analytics Code";
$t['Are you sure?'] = "Bist Du sicher?";
$t['Arrow'] = "Pfeil";
Expand Down Expand Up @@ -99,11 +99,11 @@
$t['Choose a favicon'] = "Wähle ein Favicon";
$t['Choose a logo'] = "Wähle ein Logo";
$t['City'] = "Stadt";
$t['Clean Name'] = "Rein- Name";
$t['Clean Title'] = "Rein- Titel";
$t['Clean Name'] = "Roh-Name";
$t['Clean Title'] = "Roh-Titel";
$t['Clear Cache Directory'] = "Cache-Ordner leeren";
$t['Close'] = "Schließen";
$t['Color Legend'] = "Farb- Legende";
$t['Color Legend'] = "Farb-Legende";
$t['Comment'] = "Kommentar";
$t['Comment Form'] = "Kommentar Formular";
$t['Comment thumbs up - per Person'] = "Kommentar-Likes - pro Person";
Expand All @@ -117,10 +117,10 @@
$t['Confirm'] = "Bestätigung";
$t['Confirm New Password'] = "Bestätige neues Passwort";
$t['Confirmation password does not match'] = "Das bestätigte Passwort stimmt nicht überein";
$t['Congratulations'] = "Glückwünsche";
$t['Congratulations!'] = "Glückwünsche!";
$t['Congratulations'] = "Erfolgreich";
$t['Congratulations!'] = "Erfolgreich!";
$t['Contact'] = "Kontakt";
$t['Contact Us Today!'] = "Kontaktiere uns heute!";
$t['Contact Us Today!'] = "Kontaktiere uns!";
$t['Contents'] = "Inhalt";
$t['Continue'] = "Fortsetzen";
$t['Copied'] = "Kopiert";
Expand Down Expand Up @@ -186,7 +186,7 @@
$t['Edit Video'] = "Bearbeite Video";
$t['Email All Users'] = "E-Mail an alle Nutzer";
$t['Email Verified'] = "E-Mail bestätigt";
$t['Email verification error'] = "E-Mail bestätigungsfehler";
$t['Email verification error'] = "E-Mail Bestätigungsfehler";
$t['Embed'] = "Einbetten";
$t['Embed All'] = "Alles einbetten";
$t['Embed Selected'] = "Ausgewählte einbetten";
Expand All @@ -198,7 +198,7 @@
$t['Enable SMTP'] = "SMTP aktivieren";
$t['Enable SMTP Auth'] = "SMTP Auth aktivieren";
$t['Enable WebCam Stream'] = "Aktivieren des WebCam-Stream";
$t['Encode video and audio'] = "Video und Audio Transcodieren";
$t['Encode video and audio'] = "Video und Audio Upload";
$t['Encoder'] = "Transkoder";
$t['Encoder Network'] = "Encoder-Netzwerk";
$t['Encoder URL'] = "Encoder-URL";
Expand Down Expand Up @@ -291,12 +291,12 @@
$t['Logged Users Only'] = "Nur angemeldete Benutzer";
$t['Login'] = "Anmeldung";
$t['Logo and Title'] = "Logo und Titel";
$t['MAKE SURE YOU CLICK SAVE'] = "Stellesicher, dass Du auf Speichern klickst!";
$t['MAKE SURE YOU CLICK SAVE'] = "Stelle sicher, dass Du auf Speichern klickst!";
$t['Make Stream Publicly Listed'] = "Stream öffentlich machen";
$t['Make it public'] = "Mache es öffentlich";
$t['Make sure that the video you are going to download has a duration of less than %d minute(s)!'] = "Stelle sicher, dass das Video, das Du herunterladen möchtest, eine Dauer von weniger als % d Minute (n) hat!";
$t['Make sure you have the unzip app on your server'] = "Stelle sicher, dass ein unzip-Programm auf dem Server installiert ist";
$t['Manage Clones'] = "Klone verwalten";
$t['Manage Clones'] = "Kopien verwalten";
$t['Manage Wallets'] = "Brieftaschen verwalten";
$t['Max Prints'] = "Max ausgaben";
$t['Media Owner'] = "Medieninhaber";
Expand All @@ -313,6 +313,7 @@
$t['My Account'] = "Mein Konto";
$t['My Channel'] = "Mein Kanal";
$t['My Menu'] = "Mein Menü";
$t['My Subscribers'] = "Meine Abonnenten";
$t['My videos'] = "Meine Videos";
$t['Name'] = "Name";
$t['Name can\'t be blank'] = "Name darf nicht freigelassen werden";
Expand Down Expand Up @@ -357,7 +358,7 @@
$t['Player Skin'] = "Spieler-Oberfläche";
$t['Player URL'] = "Spieler-URL";
$t['Playlist name?'] = "Name der Playlist";
$t['Please Verify Your E-mail '] = "Bitte bestätige deine E-Mail Anschrift";
$t['Please Verify Your E-mail '] = "Bitte bestätige deine E-Mail Adresse";
$t['Please sign in'] = "Bitte registrieren";
$t['Plugin'] = "Erweiterung";
$t['Plugin Form'] = "Erweiterungs-Formular";
Expand All @@ -376,8 +377,8 @@
$t['Random'] = "Zufällig";
$t['Rating'] = "Bewertung";
$t['Recover Password'] = "Passwort wiederherstellen";
$t['Recover password could not be saved!'] = "Hergestelltes Passwort konnte nicht gespeichert werden!";
$t['Recover password does not match'] = "Hergestelltes Passwort stimmt nicht überein";
$t['Recover password could not be saved!'] = "Wiederhergestelltes Passwort konnte nicht gespeichert werden!";
$t['Recover password does not match'] = "Wiederhergestelltes Passwort stimmt nicht überein";
$t['Recover password!'] = "Passwort wiederherstellen!";
$t['Refresh'] = "Aktualisiere";
$t['Region'] = "Region";
Expand Down Expand Up @@ -467,7 +468,7 @@
$t['Sub-Category-YouTube'] = "Unterkategorie-YouTube";
$t['Subscribe'] = "Abonnieren";
$t['Subscribed'] = "Abonniert";
$t['Subscribed to'] = "Aboniert von";
$t['Subscribed to'] = "Abonniert von";
$t['Subscribes'] = "Abonnierte";
$t['Subscriptions'] = "Abonnements";
$t['Success'] = "Erfolg";
Expand Down Expand Up @@ -510,7 +511,7 @@
$t['Today Views'] = "Ansichten heute";
$t['Total Amount'] = "Gesamt";
$t['Total Duration Videos (Minutes)'] = "Gesamtdauer (Minuten)";
$t['Total Subscriptions'] = "Gesamtanzahl Abonenten";
$t['Total Subscriptions'] = "Gesamtanzahl Abonnenten";
$t['Total Users'] = "Benutzer insgesamt";
$t['Total Video Comments'] = "Videokommentare insgesamt";
$t['Total Videos'] = "Videos insgesamt";
Expand Down Expand Up @@ -630,7 +631,7 @@
$t['Yes, delete it!'] = "Ja lösche es!";
$t['Yes, report it!'] = "Ja, melden!";
$t['Yes, transfer it!'] = "Ja, transferiere es!";
$t['Yes, unmute it!'] = "Ja, schalten es ein!";
$t['Yes, unmute it!'] = "Ja, schalte es ein!";
$t['You already report this video'] = "Du hast das Video schon gemeldet";
$t['You are hosting %d minutes and %d seconds of video'] = "Du verfügst über % d Minuten und % d Sekunden an Videos";
$t['You are just one click away from starting your journey with %s!'] = "Du bist nur einen Klick davon entfernt, Deine Reise mit% s zu beginnen!";
Expand Down Expand Up @@ -719,7 +720,7 @@
$t['Your user has NOT been updated!'] = "Dein Nutzer wurde NICHTgeupdatet!";
$t['Your user has been created!'] = "Dein Nutzer wurde erstellt!";
$t['Your user has been saved!'] = "Dein Nutzer wurde gespeichert!";
$t['Your user is not verified, we sent you a new e-mail'] = "Dein Konto wurde nicht verifiziert, wir haben soeben einen neuen E-Mail verschickt";
$t['Your user is not verified, we sent you a new e-mail'] = "Dein Konto wurde nicht verifiziert, wir haben soeben eine neue E-Mail verschickt";
$t['Your user or password is wrong!'] = "Dein Name oder das Passwort sind falsch!";
$t['Your video <a href=\'https://youtu.be/%s\' target=\'_blank\' class=\'btn btn-default\'><span class=\'fab fa-youtube\'></span> %s</a> was uploaded to your <a href=\'https://www.youtube.com/my_videos\' class=\'btn btn-default\' target=\'_blank\'><span class=\'fab fa-youtube-square\'></span> YouTube Account</a><br> '] = "Dein Video wurde hochgeladen auf Deinen ";
$t['Your video download is complete, it is encoding now'] = "Dein Video Download ist ok und wird nun enkodiert";
Expand All @@ -731,7 +732,7 @@
$t['about'] = "über";
$t['ago'] = "her";
$t['arrow'] = "Pfeil";
$t['audioOnly'] = "Nur audio";
$t['audioOnly'] = "Nur Audio";
$t['cat'] = "";
$t['categories'] = "Kategorien";
$t['channel'] = "Kanal";
Expand Down Expand Up @@ -776,4 +777,4 @@
$t['weeks'] = "Wochen";
$t['year'] = "Jahr";
$t['years'] = "Jahre";
$t['youtube-dl uses Python and some servers does not came with python as dafault, to install Python type:'] = "Youtube-dl verwendet Python und einige Server haben Python nicht als Standard installiert, um Python zu installieren tippe:";
$t['youtube-dl uses Python and some servers does not came with python as dafault, to install Python type:'] = "Youtube-dl verwendet Python und einige Server haben Python nicht als Standard installiert, um Python zu installieren tippe:";
3 changes: 2 additions & 1 deletion objects/Object.php
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,8 @@ function save() {
}
return $id;
} else {
die($sql . ' Error : (' . $global['mysqli']->errno . ') ' . $global['mysqli']->error);
_error_log("ObjectYPT::save Error on save: ".$sql . ' Error : (' . $global['mysqli']->errno . ') ' . $global['mysqli']->error);
return false;
}
}

Expand Down
Loading

0 comments on commit 797bbe8

Please sign in to comment.