Forum Moderators: mack
Hard at work creating a website for a charity - a volunteer effort (I'm not a web designer).
The site is nearing completion and I've created a custom 404 error file.
I've created and uploaded the .htaccess file and it is functioning correctly (pulling up the correct file when I create a 404 error).
However, when I view the directory that it's in, it's not there (does not appear in the file list), which is making it impossible to, for example, check the permissions (RW-R--R--).
Any ideas why it's not showing on the server?
Thanks SO much for any input!
Julia
[edited by: JuliaS_at_work at 7:13 pm (utc) on Feb. 1, 2008]
I don't know how you are looking at the directory - from a shell or with an FTP program?
By default, the Linux "ls" command does not list files that begin with a ".". Use "ls -a" to show all files, including those that begin with a ".". To see all files, and their permissions, use "ls -la".
This is a historical feature. Files beginning with a "." are generally configuration files of some sort, and at one time the thought was that ordinarily users wouldn't want to see these.
Now it is a jumble whether or not configuration files start with a ".", and there are also all sorts of "data" files and directories that being with a ".".
It certainly is confusing, even for a seasoned Linux user. There's not much sense or consistency to it.
If you are using an FTP program, you will need to investigate the options in your FTP program to see how to make it show you files beginning with a ".". Most FTP programs will show you all files by default.
The same is true of executing commands via FTP, site [command] [filename] works on files that are invisible via FTP (or quote [command] [filename]).
However, you shouldn't *have* to set permissions on an .htaccess file.
My backup will need to know this, as I can't yet give her access to the domain, but want her to learn about and be able to access the .htaccess file.
Also (duh me!) discovered by accident that I can see the .htaccess file through the web control panel. (too busy to THINK lately! LOL)
You're right - it already has the right permissions.
Thanks very much.