X-Git-Url: https://git.plutz.net/?a=blobdiff_plain;f=index.cgi;h=9b38362b665dffae0b6a0f59286e0aff5d8da30e;hb=1ceb1ca02e8cc1a55443152b8505e3949007ce54;hp=6f71a4b6aaa54ea0a7538c08c813a65f55c159d7;hpb=7f5bfa9a2569fb0de99df10dda9bc5bf21f23130;p=shellwiki diff --git a/index.cgi b/index.cgi index 6f71a4b..9b38362 100755 --- a/index.cgi +++ b/index.cgi @@ -78,8 +78,6 @@ attachment() { fi } -. "$_EXEC/page_edit.sh" - case "${PATH_INFO}" in /"[.]"/*) FILE "${_EXEC}/${PATH_INFO#/\[.\]}" @@ -88,8 +86,6 @@ case "${PATH_INFO}" in if [ -f "$_DATA/pages/$PATH_INFO/#page.md" \ -o -f "$_EXEC/pages/$PATH_INFO/#page.md" ]; then theme_page "${PATH_INFO}" - else - theme_404 fi ;; */"[login]") @@ -100,13 +96,10 @@ case "${PATH_INFO}" in */"[register]") theme_register ;; - */"[attachment]"/*) - : # TODO: Original attachment file - ;; */"#"*) : # TODO: Invalid page name ;; - *) - attachment "${PATH_INFO}" - ;; esac + +. "$_EXEC/page_edit.sh" +. "$_EXEC/attachment.sh"