better display of description and time for a single photo
[photo-tags.git] / htaccess_template
1
2 #    copyright 2012,2013 Arun Persaud <arun@nubati.net>
3 #
4 #    This file is part of photo-tags.
5 #
6 #    Photo-tags is free software: you can redistribute it and/or modify
7 #    it under the terms of the GNU General Public License as published by
8 #    the Free Software Foundation, either version 3 of the License, or
9 #    (at your option) any later version.
10 #
11 #    Photo-tags is distributed in the hope that it will be useful,
12 #    but WITHOUT ANY WARRANTY; without even the implied warranty of
13 #    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14 #    GNU General Public License for more details.
15 #
16 #    You should have received a copy of the GNU General Public License
17 #    along with Photo-tags.  If not, see <http://www.gnu.org/licenses/>.
18
19 <IfModule mod_rewrite.c>
20 RewriteEngine on
21
22 RewriteBase   /<insert web base url here>
23
24 # hide git directory (and others)
25 RedirectMatch 404 \.(git|cvs|svn|bzr|hg)(/.*|$)
26
27 # use autoversioning of js and css files
28 RewriteRule ^(.*)\.[[:xdigit:]]{32}\.(css|js)$ $1.$2 [L]
29
30
31 ### make the url nice and clean; the comments shows an url that should be matched
32
33 # web_base/tag/me+berlin/pic/id
34 RewriteRule tag/([-_\s,a-zA-Z0-9+]*)/pic/([0-9]*) index.php?tag=$1&pic=$2 [L]
35
36 # web_base/tag/tag1+tag2/page/4
37 RewriteRule tag/([-_\s,a-zA-Z0-9+]*)/page/([0-9]*) index.php?tag=$1&page=$2 [L]
38
39 # web_base/tag/tag1+tag2
40 RewriteRule tag/([-_\s,a-zA-Z0-9+]*) index.php?tag=$1 [L]
41
42 # web_base/pic/17
43 RewriteRule pic/([0-9]*) index.php?pic=$1 [L]
44
45 # web_base/page/4
46 RewriteRule page/([0-9]*) index.php?page=$1 [L]
47
48
49 </IfModule>