# copyright 2012,2013 Arun Persaud # # This file is part of photo-tags. # # Photo-tags is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # Photo-tags is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Photo-tags. If not, see . RewriteEngine on RewriteBase / # hide git directory (and others) RedirectMatch 404 \.(git|cvs|svn|bzr|hg)(/.*|$) # use autoversioning of js and css files RewriteRule ^(.*)\.[[:xdigit:]]{32}\.(css|js)$ $1.$2 [L] ### make the url nice and clean; the comments shows an url that should be matched # web_base/tag/me+berlin/pic/id RewriteRule tag/([-_\s,a-zA-Z0-9+]*)/pic/([0-9]*) index.php?tag=$1&pic=$2 [L] # web_base/tag/tag1+tag2/page/4 RewriteRule tag/([-_\s,a-zA-Z0-9+]*)/page/([0-9]*) index.php?tag=$1&page=$2 [L] # web_base/tag/tag1+tag2 RewriteRule tag/([-_\s,a-zA-Z0-9+]*) index.php?tag=$1 [L] # web_base/pic/17 RewriteRule pic/([0-9]*) index.php?pic=$1 [L] # web_base/page/4 RewriteRule page/([0-9]*) index.php?page=$1 [L]