X-Git-Url: https://jasonwoof.com/gitweb/?a=blobdiff_plain;f=metaform%2Fhtaccess;h=ebf4f8b36788c75bb69a918b56d0e4887eb3fe59;hb=9a3136a5bee66e1055ffb566373952b6054dd7bf;hp=eb2ad6de59c221895c29858067efd135a764ba0c;hpb=7add2ea3f61e40c5f0f5539ac6e02533c9390db4;p=wfpl.git diff --git a/metaform/htaccess b/metaform/htaccess index eb2ad6d..ebf4f8b 100644 --- a/metaform/htaccess +++ b/metaform/htaccess @@ -1,3 +1,42 @@ +# Tell php not to mangle form data or let the user set globals. +php_flag register_globals off +php_flag magic_quotes_gpc off + +# All your files are UTF-8... RIGHT? +AddDefaultCharset UTF-8 + +# You should rename your images and css files when you change them so they can +# be cached forever + + ExpiresActive On + ExpiresDefault A31536000 + + +# To enable larger uploads, you'll need both of these: +# php_value post_max_size 205M +# php_value upload_max_filesize 200M + + +############ START OF PRETTY URLS SETTINGS ############ +# This section contains directives to enable pretty URLs, including setting +# page urls to run your site-wide config file, which in turn can run +# wfpl_main() + +# To have "pretty" urls (no file extension at the end) we use mod_rewrite. But +# first we've got to disable a couple url-mangling features of apache that take +# precedence over mod_rewrite: +Options -MultiViews +DirectorySlash Off + +# Activate mod_rewrite: RewriteEngine on -RewriteRule ^$ /~form~/run.php -RewriteRule ^[^/]*\.html$ /~form~/run.php + +# Unfortunately, the rewrite rules only work with absolute paths, so if your +# files are not at the top level of the domain, you'll have to customize this +# part. Here's the config for running at the top level: +RewriteRule ^[^/.]*$ /wfpl_main.php [L] + +# use this line instead if you have this (.htaccess) file and your php and html +# files in the ~form~ directory: +#RewriteRule ^[^/.]*$ /~form~/run.php +############ END OF PRETTY URLS SETTINGS ############