From 6f754cf58e0a34caf2204ea23ff6c64a20e15658 Mon Sep 17 00:00:00 2001 From: dangjinghao Date: Tue, 9 Sep 2025 15:21:24 +0800 Subject: [PATCH 1/2] Update `getLink` method to use `wl` function for permalink generation --- inc/Menu/Item/Permalink.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/inc/Menu/Item/Permalink.php b/inc/Menu/Item/Permalink.php index eccd0e16..6e6f87e9 100644 --- a/inc/Menu/Item/Permalink.php +++ b/inc/Menu/Item/Permalink.php @@ -29,7 +29,7 @@ public function getLink() global $ID; global $INFO; - return DOKU_URL . DOKU_SCRIPT . '?id=' . $ID . '&rev=' . $INFO['lastmod']; + return wl($ID, 'rev=' . $INFO['lastmod'], true); } public function getLinkAttributes($classprefix = 'menuitem ') From 756cb429cc1bf5ce39dfb03322a7e1822da28618 Mon Sep 17 00:00:00 2001 From: dangjinghao Date: Tue, 9 Sep 2025 15:48:07 +0800 Subject: [PATCH 2/2] Fix `getLink` method to specify `&` separator in permalink generation when `userewrite` is `none` --- inc/Menu/Item/Permalink.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/inc/Menu/Item/Permalink.php b/inc/Menu/Item/Permalink.php index 6e6f87e9..138fb81a 100644 --- a/inc/Menu/Item/Permalink.php +++ b/inc/Menu/Item/Permalink.php @@ -29,7 +29,7 @@ public function getLink() global $ID; global $INFO; - return wl($ID, 'rev=' . $INFO['lastmod'], true); + return wl($ID, 'rev=' . $INFO['lastmod'], true, '&'); } public function getLinkAttributes($classprefix = 'menuitem ')