Created
June 2, 2011 00:08
-
-
Save andymckay/1003642 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Index: webroot/.htaccess | |
=================================================================== | |
--- webroot/.htaccess (revision 89756) | |
+++ webroot/.htaccess (working copy) | |
@@ -32,12 +32,12 @@ | |
## addon icons | |
# Short (<3 digits) get funneled into /0/ | |
- RewriteRule ^[^/]+/[^/]+/images/addon_icon/(\d{1,3})-(32|48|64).png /img/uploads/addon_icons/0/$1-$2.png [L] | |
- RewriteRule ^[^/]+/[^/]+/images/addon_icon/(\d{1,3}).png /img/uploads/addon_icons/0/$1-32.png [L] | |
+ RewriteRule ^([^/]+/[^/]+/|)images/addon_icon/(\d{1,3})-(32|48|64).png /img/uploads/addon_icons/0/$2-$3.png [L] | |
+ RewriteRule ^([^/]+/[^/]+/|)images/addon_icon/(\d{1,3}).png /img/uploads/addon_icons/0/$2-32.png [L] | |
# Everyone else gets processed into another dir | |
- RewriteRule ^[^/]+/[^/]+/images/addon_icon/((\d*?)\d{1,3})-(32|48|64).png /img/uploads/addon_icons/$2/$1-$3.png [L] | |
- RewriteRule ^[^/]+/[^/]+/images/addon_icon/((\d*?)\d{1,3}).png /img/uploads/addon_icons/$2/$1-32.png [L] | |
+ RewriteRule ^([^/]+/[^/]+/|)images/addon_icon/((\d*?)\d{1,3})-(32|48|64).png /img/uploads/addon_icons/$3/$2-$4.png [L] | |
+ RewriteRule ^([^/]+/[^/]+/|)images/addon_icon/((\d*?)\d{1,3}).png /img/uploads/addon_icons/$3/$2-32.png [L] | |
## Rewrite images that think they belong in /userpics/// to be /userpics/0/0 | |
@@ -47,7 +47,7 @@ | |
## /addon_icons | |
## collection icons | |
- RewriteRule ^[^/]+/[^/]+/images/collection_icon/((\d*?)\d{1,3}).png /img/uploads/collection_icons/$2/$1.png [L] | |
+ RewriteRule ^([^/]+/[^/]+/|)images/collection_icon/((\d*?)\d{1,3}).png /img/uploads/collection_icons/$3/$2.png [L] | |
## Rewrite images that think they belong in /userpics/// to be /userpics/0/0 | |
RewriteCond %{REQUEST_FILENAME} !-f |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment