diff --git a/assets/src/img/user.png b/assets/src/img/user.png new file mode 100644 index 000000000..0996c6b83 Binary files /dev/null and b/assets/src/img/user.png differ diff --git a/include/top.php b/include/top.php index 864c33903..bae8e5fef 100755 --- a/include/top.php +++ b/include/top.php @@ -469,15 +469,10 @@ if (Auth::check()) {
'; - $user_photo = $user->photo; - if ($user_photo) { - echo ' - '.$user['username'].''; - } else { - echo ' - '; - } + $user_photo = $user->photo ?: $rootdir.'/assets/dist/img/user.png'; + echo ' + '.$user['username'].'
diff --git a/modules/utenti/info.php b/modules/utenti/info.php index 1d732802b..466b02d48 100755 --- a/modules/utenti/info.php +++ b/modules/utenti/info.php @@ -44,23 +44,16 @@ $module = Module::where('name', 'Utenti e permessi')->first(); echo '
-
+

'.$user['username'].'

'.$user['gruppo'].'
'; -$user_photo = $user->photo; -if ($user_photo) { - echo ' - '.$user['username'].''; -} else { - echo ' - '; -} - +$user_photo = $user->photo ?: $rootdir.'/assets/dist/img/user.png'; echo ' + '.$user['username'].'