diff options
| author | winter | 2025-01-14 20:44:49 +0000 |
|---|---|---|
| committer | winter | 2025-01-14 20:44:49 +0000 |
| commit | 4d7f8450d9a842e2f69754ccaa4202710328dcb7 (patch) | |
| tree | 60e90ff7ebbf069e04faf665d68861970eaee000 /templates/actor_profile_page.php | |
| parent | 0f427b4b6f75134b2c25b7e5f8a515be2cec97f5 (diff) | |
add (un)follow button to profile
also other stuff i forgot what exactly
Diffstat (limited to 'templates/actor_profile_page.php')
| -rw-r--r-- | templates/actor_profile_page.php | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/templates/actor_profile_page.php b/templates/actor_profile_page.php index e7d28b7..649069d 100644 --- a/templates/actor_profile_page.php +++ b/templates/actor_profile_page.php @@ -9,11 +9,16 @@ call_template('skeleton', [ global $actor; call_template('actor_profile', ['actor' => $actor]); echo '<hr>'; - $notes = Note::findAllWithAuthor($actor, 50); + $notes = Note::findAllWithAuthor($actor, 20); if (count($notes) == 0) { call_template('placeholder_text', ['message' => __('user.notes.placeholder')]); - } - foreach ($notes as $n) { - call_template('note', ['note' => $n]); + } else { + foreach ($notes as $n) { + call_template('note', ['note' => $n]); + } + $countNotShown = Note::countWithAuthor($actor) - count($notes); + if ($countNotShown >= 0) { + call_template('placeholder_text', ['count' => $countNotShown]); + } } });
\ No newline at end of file |
