Forum Moderators: open

Message Too Old, No Replies

.htaccess file 'disappears' on server

...apparently deleted by server?

         

pgp566

8:21 pm on Apr 24, 2008 (gmt 0)

10+ Year Member



I would really appreciate any help... have generated an .htaccess file containing a number of 301 redirects. I have carefully checked the syntax (of the 301 redirects) and I believe it's correct - also checked by someone else on this list.

The problem is that the .htaccess file disappears on the server immediately after it is uploaded. I don't think it's 'invisible' because I can see it immediately after uploading (using Dreamweaver) but as soon as I refresh or re-connect it has gone. Have tried repeatedly, also tried using ws_ftp.

It seems that the server is deleting the .htaccess file (?!?) The server is running Apache/2.0.55 (Unix). I have contacted my ISP but they are very slow to respond. Any clues at all?

Many thanks
Philip
--

coopster

8:27 pm on Apr 24, 2008 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



Many FTP clients have a setting that you have to turn on in order to show "hidden" files which often means those beginning with a period as in .htaccess. Even then, the server may also be set to not display those filenames. A sure way to find out is the SSH command line which your ISP likely will not allow if it is shared hosting.

londrum

8:27 pm on Apr 24, 2008 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



do the redirects work?

try and upload another file called something else, but starting with a dot.
as you have already guessed, some set-ups will not display any filenames starting with a dot. if the same thing happens to this other one, then you will know it's that.

[edit. same answer. posted at the same time!]

pgp566

11:01 pm on Apr 24, 2008 (gmt 0)

10+ Year Member



Hi coopster and londrum, thanks a lot!

Sure enough, based on your tips I dug into this some more and found that by entering "-al" into the file mask of ws-ftp it shows the .htaccess file!

I should have known this because I have some experience with Unix and commands like "ls -al" are second nature. It just never occured to me that ftp programs would hide this stuff by default. And nothing I do in Dreamweaver will show the file. Wow, if it baffled me I'm sure it has baffled a lot of others out there...

Thanks muchly!
Philip