How do yous top anyone else from viewing your .htaccess file please?

Any help appreciated.

Dez.

No, you forgot the dot
[noparse]http://www.example.com/[/noparse][B].[/B]htaccess

But yes, I’d say most websites have their .htaccess in the root.

Why do you want to look at someone else’s .htaccess anyway?

Thanks Scallio, I’m just trying to view someone else’s, so don’t necessarily know their path. By default, would most peoples be at www.example.com/htaccess ?

Thanks, so I don’t need to do anything, to prevent anyone from seeing the .htaccess file then ?

Would that be just something simple, like www.xyzwebsite.com/.htaccess

or www.xyzwebsite.com/.htaccess.txt

? ?

Try accessing the .htaccess file in your browser yourself.
If you get a 403 forbidden all is well :slight_smile:

.htaccess files are hidden by default afaik

Due to this default setting in httpd.conf


<FilesMatch "^\\.ht">
    Order allow,deny
    Deny from all
    Satisfy All
</FilesMatch>

fire up your browser and go to [noparse]http://www.example.com/.htaccess[/noparse]

Of course if the .htaccess is situated in a path you need to browse to

[noparse]http://www.example.com/some/path/.htaccess[/noparse]

Replace [noparse]www.example.com[/noparse] with your domain name.