diff --git a/bin/cronTask.sh b/bin/cronTask.sh
index d776b22..0ffc103 100644
--- a/bin/cronTask.sh
+++ b/bin/cronTask.sh
@@ -18,7 +18,7 @@ do
then
while read urlHash url destination
do
- youtube-dl -R 0 -q -c --write-thumbnail --write-info-json --recode-video webm --no-check-certificate -f 46/37/45/22/44/35/34/5 -o "$urlHash.%(ext)s" "$url"
+ youtube-dl -R 0 -c --write-thumbnail --write-info-json --recode-video webm --no-check-certificate -f 45/46/37/45/22/44/35/34/5 -o "$urlHash.%(ext)s" "$url"
sleep 5
if [ ! -f $urlHash.*.part ]
then
@@ -29,3 +29,5 @@ do
done < $file
fi
done
+
+# -rc_lookahead 16 -g 360 -threads 3
diff --git a/inc/content.php b/inc/content.php
index 6d9445c..921c96d 100644
--- a/inc/content.php
+++ b/inc/content.php
@@ -1,7 +1,4 @@
@@ -14,43 +11,47 @@ if (!empty($ci['ac']) && $ci['ac'] === 'login') {
-
+
';
}
if (!empty($ci['ac']) && $ci['ac'] === 'newDir') {
- if (!empty($ci['op']) && (int)$ci['op'] === 1) {
- verifToken($ci['token']);
- $addDir = addDir($ci['newDir'], $ci['bc'], $fullListDir);
- } else {
echo '
';
+}
+if (!empty($ci['ac']) && $ci['ac'] === 'renDir') {
+ if (empty($ci['op'])){
+ $currentDir = getCurrentDir($ci['bc']);
+ echo '';
}
}
if (!empty($ci['ac']) && $ci['ac'] === 'addVideo') {
- if (!empty($ci['op']) && (int)$ci['op'] === 1) {
- verifToken($ci['token']);
- $addVideo = addVideo($ci, $fullListFile);
- } else {
echo '';
}
-}
+
+//n_print($fullListDir);
if (!empty($ci['ac']) && $ci['ac'] === 'view') {
if (!empty($ci['op']) && (int)$ci['op'] === 1) {
verifToken($ci['token']);
@@ -125,8 +127,9 @@ if ($ci['ac'] === 'view' && !empty($listCurrentFile)) {
if (!empty($videoInfo)) {
echo '';
echo '
', $videoInfo['title'], ' (', $videoInfo['originalTitle'], ')
';
- echo '
';
diff --git a/inc/topMenu.php b/inc/topMenu.php
index c4b63f8..6d15bf2 100644
--- a/inc/topMenu.php
+++ b/inc/topMenu.php
@@ -4,6 +4,7 @@
if ($_SESSION['log'] === true) {
echo '
New directory
+ Rename directory
Add videos';
} else {
echo 'Login';
diff --git a/index.php b/index.php
index 8d5f05b..b2cf0d0 100644
--- a/index.php
+++ b/index.php
@@ -102,6 +102,11 @@ function checkSecure() {
function logout() {
}
+function getCurrentDir($bc) {
+ $currentDir = end(str_split($bc, 8));
+ return $currentDir;
+}
+
function genToken() {
$token = sha1(uniqid(rand(), true).'_'.mt_rand());
$_SESSION['token'] = $token;
@@ -153,12 +158,12 @@ function n_print($data, $name = '') {
$aBackTrace = debug_backtrace();
echo '', $name, '
';
echo '
-