Forum Moderators: phranque
I imagine that the hotlinking type situation may be of assistance, but I am unsure of the specifics.
Eg
RewriteCond %{HTTP_REFERER}!^http://mysite.co.uk/.*$ [NC]
RewriteCond %{HTTP_REFERER}!^http://www.mysite.co.uk/.*$ [NC]
RewriteRule .*\.(inc)$ - [F]
However that only protects .inc files from hotlinking. Will the * attribute work for everything. I only really need to stop people browsing.
Cheers
RewriteRule \.inc$ - [F,L]
Any PHP scripts including the .inc files won't be affected _unless_ they include using a URL instead of a relative or absolute filepath.