1 ### GNU social "fancy URL" setup
3 # Change the "RewriteBase" in the new .htaccess file to be the URL path
4 # to your GNU Social installation on your server. Typically this will
5 # be the path to your GNU Social directory relative to your Web root.
6 # If you are installing it in the root directory, leave it as '/'.
8 # If it doesn't work, double-check that AllowOverride for the GNU Social
9 # directory is 'All' in your Apache configuration file. This can be
10 # * /etc/apache2/apache2.conf (generic)
11 # * /etc/apache2/sites-available/default(on Debian and Ubuntu)
12 # * ...many other variations depending on distribution...
14 # See the Apache documentation for .htaccess files for more details:
15 # https://httpd.apache.org/docs/2.4/howto/htaccess.html
17 # Also, check that mod_rewrite is installed and enabled:
18 # https://httpd.apache.org/docs/2.4/mod/mod_rewrite.html
21 <IfModule mod_rewrite.c>
24 # NOTE: change this to your actual GNU social base URL path,
25 # minus the domain part:
27 # https://social.example.com/ => /
28 # https://example.com/social/ => /social/
33 ## Uncomment these if having trouble with API authentication
34 ## when PHP is running in CGI or FastCGI mode.
36 #RewriteCond %{HTTP:Authorization} ^(.*)
37 #RewriteRule ^(.*) - [E=HTTP_AUTHORIZATION:%1]
39 RewriteCond %{REQUEST_FILENAME} !-f
40 RewriteCond %{REQUEST_FILENAME} !-d
41 RewriteRule (.*) index.php?p=$1 [L,QSA]
43 ## You can also use PATHINFO by using this RewriteRule instead:
44 # RewriteRule (.*) index.php/$1 [L,QSA]
47 <FilesMatch "\.(ini)">
48 # For mod_access_compat in Apache <2.4
51 # Use this instead for Apache >2.4 (mod_authz_host)