diff options
author | Mario <mario@mariovavti.com> | 2025-05-29 10:13:32 +0000 |
---|---|---|
committer | Mario <mario@mariovavti.com> | 2025-05-29 10:13:32 +0000 |
commit | 20148d23f1a2f1a102e736075c8985041144e621 (patch) | |
tree | 6c2c04195b5044342f481a4eadceafb2b111832e /Zotlabs/Module | |
parent | bdcee46138dd247d7f2e4508aff54e0ffe6d8a07 (diff) | |
download | volse-hubzilla-20148d23f1a2f1a102e736075c8985041144e621.tar.gz volse-hubzilla-20148d23f1a2f1a102e736075c8985041144e621.tar.bz2 volse-hubzilla-20148d23f1a2f1a102e736075c8985041144e621.zip |
toplevel comments pagination: initial commit
Diffstat (limited to 'Zotlabs/Module')
-rw-r--r-- | Zotlabs/Module/Request.php | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/Zotlabs/Module/Request.php b/Zotlabs/Module/Request.php index 0174694b2..cdce4c66a 100644 --- a/Zotlabs/Module/Request.php +++ b/Zotlabs/Module/Request.php @@ -29,9 +29,15 @@ class Request extends Controller { $mid = $_GET['mid']; $parent = intval($_GET['parent']); + + $offset = null; + if ($_GET['verb'] === 'load') { + $offset = intval($_GET['offset']); + } + $module = strip_tags($_GET['module']); - $items = items_by_thr_parent($mid, $parent); + $items = items_by_thr_parent($mid, $parent, $offset); xchan_query($items); $items = fetch_post_tags($items,true); @@ -44,7 +50,7 @@ class Request extends Controller public function get() : string { - if ($_GET['verb'] === 'comment') { + if (in_array($_GET['verb'], ['comment', 'load'])) { return self::processSubthreadRequest(); } |