X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=mod%2Fvideos.php;h=2ee73c211d438c1787432bebb2069e1f7fe312b2;hb=7034d6efbd988e7481ac6f5d6413a8925221ed6b;hp=433ce5fc63f82e2e150b7b7c9ce87325553ba50e;hpb=42c2e09382d3b2846a0cb709d88cda97e717424f;p=friendica.git diff --git a/mod/videos.php b/mod/videos.php index 433ce5fc63..2ee73c211d 100644 --- a/mod/videos.php +++ b/mod/videos.php @@ -1,12 +1,14 @@ argc > 1) auto_redir($a, $a->argv[1]); @@ -102,7 +104,7 @@ function videos_init(App &$a) { -function videos_post(App &$a) { +function videos_post(App $a) { $owner_uid = $a->data['user']['uid']; @@ -182,7 +184,7 @@ function videos_post(App &$a) { -function videos_content(App &$a) { +function videos_content(App $a) { // URLs (most aren't currently implemented): // videos/name @@ -356,7 +358,9 @@ function videos_content(App &$a) { $a->set_pager_itemspage(20); } - $r = q("SELECT hash, `id`, `filename`, filetype FROM `attach` + $r = q("SELECT hash, ANY_VALUE(`id`) AS `id`, ANY_VALUE(`created`) AS `created`, + ANY_VALUE(`filename`) AS `filename`, ANY_VALUE(`filetype`) as `filetype` + FROM `attach` WHERE `uid` = %d AND filetype LIKE '%%video%%' $sql_extra GROUP BY hash ORDER BY `created` DESC LIMIT %d , %d", intval($a->data['user']['uid']),