summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeffery To <jeffery.to@gmail.com>2009-10-08 11:45:32 +0800
committerJeffery To <jeffery.to@gmail.com>2009-10-22 12:46:57 +0800
commit834a876dd0998464cade1cdd0fe2fe8c9ab17dcc (patch)
tree6bd353d012c2a721e38f3ffd4a7e4eda540b30bd
parent3f06bfc042e34ce97e1f1476faadb67fc5edd282 (diff)
mod_rewrite rule for getfile
-rw-r--r--htaccess.sample8
1 files changed, 8 insertions, 0 deletions
diff --git a/htaccess.sample b/htaccess.sample
index 37eb8e01e..91ae9da9b 100644
--- a/htaccess.sample
+++ b/htaccess.sample
@@ -5,6 +5,14 @@
RewriteBase /mublog/
+ # If your site is private and want to only allow logged-in users to
+ # be able to download file attachments, uncomment this rule.
+ #
+ # If you have a custom attachment path
+ # ($config['attachments']['path']), change "file/" to match.
+ #
+ #RewriteRule ^file/(.*) getfile/$1
+
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule (.*) index.php?p=$1 [L,QSA]