You must put your .htaccess
in the root directory of your web application.
For example, if the .htaccess
content is relevant to your site "mysite" whose path in your filesystem is .../www/mysite
, you must put your .htaccess
in .../www/mysite
.