X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=mod%2Fvideos.php;h=e5a0887bb9f3a2e6e22c1ade3fe262977d94886f;hb=0c9cc29a51941eb572bf16fd5489d0947d47d033;hp=607c900eb5cbccadf7a2be326a9105e884f5d0b2;hpb=b3992e1c65ca360595ed2e68c40b48e40767f007;p=friendica.git diff --git a/mod/videos.php b/mod/videos.php index 607c900eb5..e5a0887bb9 100644 --- a/mod/videos.php +++ b/mod/videos.php @@ -15,23 +15,38 @@ function videos_init(&$a) { return; } + nav_set_selected('home'); + $o = ''; if($a->argc > 1) { $nick = $a->argv[1]; - $r = q("SELECT * FROM `user` WHERE `nickname` = '%s' AND `blocked` = 0 LIMIT 1", + $user = q("SELECT * FROM `user` WHERE `nickname` = '%s' AND `blocked` = 0 LIMIT 1", dbesc($nick) ); - if(! count($r)) + if(! count($user)) return; - $a->data['user'] = $r[0]; + $a->data['user'] = $user[0]; + $a->profile_uid = $user[0]['uid']; + + $profile = get_profiledata_by_nick($nick, $a->profile_uid); + + if((intval($profile['page-flags']) == PAGE_COMMUNITY) || (intval($profile['page-flags']) == PAGE_PRVGROUP)) + $account_type = t('Forum'); + else + $account_type = ""; - $o .= '