Take the 2-minute tour ×

I have some files on the server which are protected using htaccess. My problem is that I have a form (php) which will be used by clients to submit some data and this form accesses some files which are protected (e.g. controller.php where I'm querying the db to check if the email is in the database and other types of functionality).

Is there a way to specify that those protected files should be accessible if they are accessed from my form? Otherwise request password or something similar?

What are my options in order to be able to protect my files but still let them be accessed by the form (which is available for users)?

share|improve this question
beeing accessible from the form means that is will be acessible from anything else too –  Oussama Sep 5 '12 at 13:43
add comment

1 Answer

I think you could create a RewriteCond checking the HTTP-Referer header as described in the link down below.


share|improve this answer
add comment

Your Answer


