[TYPO3] Need help on .htaccess/realURL
Andreas Koppa
akoppa at gmail.com
Mon Feb 27 23:40:19 CET 2006
Hello,
Regarding Apache I'm just a copy/paste hacker. So, I badly need help on
.htaccess/realURL.
In fact I prefer not to use .htaccess but i did because of people stealing
my bandwidth. Now I´m again forced to use it because of realURL. Why T3
relies on that solution while other simpler applications i.e. WordPress use
Permalinks (realURL's) without .htaccess? That´s something to think about.
Anyway, this is my current .htaccess to avoid hotlinking:
RewriteEngine on
RewriteCond %{HTTP_REFERER} !^http://domain.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://domain.com$ [NC]
RewriteCond %{HTTP_REFERER} !^http://subdom1.domain.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://subdom1.domain.com$ [NC]
RewriteCond %{HTTP_REFERER} !^http://subdom2.domain.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://subdom2.domain.com$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.domain.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.domain.com$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.subdom1.domain.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.subdom1.domain.com$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.subdom2.domain.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.subdom2.domain.com$ [NC]
RewriteRule .*\.(jpg|gif|bmp)$ http://www.domain.com/gif/stolen.jpeg [R,NC]
This is required by T3 and realURL:
RewriteEngine On
RewriteRule ^(typo3|typo3temp|typo3conf|t3lib|tslib|fileadmin|uploads|showpic\.php)/
- [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-l
RewriteRule .* index.php [L]
I have tested the later independently and works. The question is how do
I combine the scripts in order to fulfill both requirements without compromising
each other? By the way, there are many index.php in subdirs.
Thanks a lot.
More information about the TYPO3-english
mailing list