.htaccess/301 redirects not working - what

Posted By: SportsGuy (Staff)
Posted On: 2008-Jun-24 20:01

Since I can't delete this, it seems, I'll mark it solved. wink

File was misnamed - missing the . (dot) at the beginning of the file name on the server - hence it was recognized for what it was - code in use works fine now. wink


Posted By: Prowler (Staff)
Posted On: 2008-Jun-25 05:24

Most Windows based text editors will refuse to name the file with a preceding dot. So the workaround would be to name whatever is convenient and then open a command shell from where you can rename the file to .htaccess

BTW, Windows CLI shell is not so powerful. I use the Cygwin shell. It is a linux bash shell from RedHat.


Posted By: SportsGuy (Staff)
Posted On: 2008-Jun-25 13:25

Thanks Prowler. smile

I'm guessing the hacks at GD didn't pay attention when they mirrored my server to swap to the new, upgraded box. sad

Until recently, I only even used UltraEdit to manage my .htaccess files to ensure they were clean, non-Windows-molested .txt's. Now, with my new "work" laptop, I only have NotePad installed. sad Still, seems to work.

I ended up doing exactly as you'd suggested when I fixed this - simply selected the file on the server and renamed it.

It has occurred to me - over the years - that most things in need of work because they are not working, need only a small change made, so I look for those simple, one-character-tweak things first now.

Following that methodology has saved me a LOT of grief over the years.

...and SEF is where I learned that approach - by taking advice from folks like you, bhartzer, gs1md, FlyingRose, OAC, excel and others.

Thanks to you all. smile


Posted By: g1smd (Staff)
Posted On: 2008-Jun-25 20:06

I name .htaccess files like "htaccess.2008.06.24.searchengineforums.txt" on my computer, so that I know which site it is for and when it was last edited.

I rename them only once they have been uploaded to the server.


Posted By: SportsGuy (Staff)
Posted On: 2008-Jun-26 00:53

Similar thinking here, G, though I tend to get anal and create a folder with the name of the domain the htaccess is for, then stick the file (and any other related files) into the folder.


Posted By: g1smd (Staff)
Posted On: 2008-Jun-26 00:56

Sure. I do sort all of the files out into folders by site too, but for "short" filenames it is just too easy to upload the wrong file to the wrong site, hence the longer naming convention.

So with the longer names, even if I upload the wrong file, no damage is caused until I am about to rename the file to .htaccess. That is the point at which I would hopefully notice the problem.