Forum Moderators: phranque
RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.+)$ index.php?title=$1 [L,QSA]
Options +FollowSymlinks
RewriteEngine on
# Link for the Sitemap
RewriteRule ^sitemap(.*)\.xml$ sitemap.php?page=$1 [L,NC]
RewriteCond %{HTTP_REFERER} !^http://example.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://example.com$ [NC]
RewriteRule .*\.(jpg|jpeg|gif|png|bmp|mp3)$ http://example.com/Hotlink_Protection [R,NC] [edited by: incrediBILL at 10:38 pm (utc) on Mar 23, 2012]
[edit reason] site link removed [/edit]
RewriteRule .*\.(jpg|jpeg|gif|png|bmp|mp3)$ http://example.com/Hotlink_Protection [R,NC]
# Link for the Sitemap
RewriteRule ^sitemap(.*)\.xml$ sitemap.php?page=$1 [L,NC]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.+)$ index.php?title=$1 [L,QSA]
Options +FollowSymlinks
RewriteEngine on
RewriteCond %{HTTP_REFERER} !^http://example.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://example.com$ [NC] [edited by: incrediBILL at 10:39 pm (utc) on Mar 23, 2012]
[edit reason] site link removed [/edit]
[edited by: incrediBILL at 10:40 pm (utc) on Mar 23, 2012]
[edit reason] site link removed [/edit]
RewriteRule .*\.(jpg|jpeg|gif|png|bmp|mp3)$ [example.com...] [R,NC]
Options +FollowSymlinks
RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{HTTP_REFERER} !^http://example.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://example.com$ [NC]
RewriteRule ^(.+)$ index.php?title=$1 [L,QSA]
# Link for the Sitemap
RewriteRule ^sitemap(.*)\.xml$ sitemap.php?page=$1 [L,NC] [edited by: incrediBILL at 10:40 pm (utc) on Mar 23, 2012]
Is this correct?
[edited by: incrediBILL at 10:41 pm (utc) on Mar 23, 2012]
[edit reason] exemplified [/edit]
Options +FollowSymlinks
RewriteEngine On
# hotlink code
RewriteCond %{HTTP_REFERER} !^http://(www\.)?example\.com [NC]
RewriteRule \.(jpe?g|gif|png|bmp|mp3)$ http://example.com/Hotlink_Protection [R=302,NC,L]
# add your www to non-www canonical redirect code here
# ->
# sitemap rewrite
RewriteRule ^sitemap([^.]+)\.xml$ /sitemap.php?page=$1 [NC,L]
# catch-all rewrite
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule (.+) /index.php?title=$1 [QSA,L] [edited by: incrediBILL at 10:42 pm (utc) on Mar 23, 2012]
[edit reason] site link removed [/edit]
[edited by: incrediBILL at 10:43 pm (utc) on Mar 23, 2012]
[edit reason] site link removed [/edit]
what chance do I have of understanding it
Lucy suggested a 301 for the Hotlink code but you've chosen 302.
MediaWiki
www.example.com to http://example.com? [edited by: incrediBILL at 10:43 pm (utc) on Mar 23, 2012]
[edit reason] site link removed [/edit]