.htaccess redirect certain files
I don`t know anything about .htaccess files except how to secure a folder or deny access.
I want to deny direct access to .js
files (by typing the file name in url) on my server, say the files are stored in a folder named /js/
how can I use the .htaccess 开发者_如何学JAVAto do that?
You cannot do that.
Actually there is no 'direct access' or 'indirect access'. The browser accesses the JS file the same way when you load it from a SCRIPT tag and when you try to load it separately (typing the file name in browser).
精彩评论