]> git.plutz.net Git - shellwiki/commitdiff
dialog for user settings, separate handler for special pages
authorPaul Hänsch <paul@plutz.net>
Mon, 16 May 2022 12:28:30 +0000 (14:28 +0200)
committerPaul Hänsch <paul@plutz.net>
Mon, 16 May 2022 12:28:30 +0000 (14:28 +0200)
handlers/10_page.sh
handlers/20_account.sh [new file with mode: 0755]
macros/wikiform
pages/[wiki]/settings/#page.md [new file with mode: 0644]

index 70e70e7fa75a0e8fd4e48ddb399c0fb8dcf342da..b34aa1b21dac7fc054261ebb566fa4ed4d00fbf4 100755 (executable)
@@ -56,18 +56,6 @@ case "${PATH_INFO}" in
   */\[*\]/*)
     return 1
     ;;
-  */"[login]")
-    theme_page "/[wiki]/login/"
-    return 0
-    ;;
-  */"[register]")
-    theme_page "/[wiki]/register/"
-    return 0
-    ;;
-  */"[invite]")
-    theme_page "/[wiki]/invite/"
-    return 0
-    ;;
   */)
     theme_page "${PATH_INFO}"
     return 0
diff --git a/handlers/20_account.sh b/handlers/20_account.sh
new file mode 100755 (executable)
index 0000000..73edb0f
--- /dev/null
@@ -0,0 +1,22 @@
+#!/bin/sh
+
+case "${PATH_INFO}" in
+  */"[login]")
+    theme_page "/[wiki]/login/"
+    return 0
+    ;;
+  */"[register]")
+    theme_page "/[wiki]/register/"
+    return 0
+    ;;
+  */"[invite]")
+    theme_page "/[wiki]/invite/"
+    return 0
+    ;;
+  */"[settings]")
+    theme_page "/[wiki]/settings/"
+    return 0
+    ;;
+esac
+
+return 1
index 7eb3f1c5a536c3bbd3330a305bef02c176ec3f09..ecb003b437b67f27edcc01f6f96e389960d64264 100755 (executable)
@@ -15,4 +15,7 @@ case $action in
   invite)
     w_user_invite |"$_EXEC/cgilite/html-sh.sed"
     ;;
+  settings)
+    w_user_update |"$_EXEC/cgilite/html-sh.sed"
+    ;;
 esac
diff --git a/pages/[wiki]/settings/#page.md b/pages/[wiki]/settings/#page.md
new file mode 100644 (file)
index 0000000..9dd280f
--- /dev/null
@@ -0,0 +1,7 @@
+%nocache
+
+Change Your Password
+-----------------
+<<wikiform settings>>
+
+[Return](./)