.htaccess not working on windows
Posted by: zorro56 (---.tampfl.fios.verizon.net)
Date: March 09, 2007 10:01PM

Anyone know how to get .htaccess to work for your windows. I need to be able to test out search freindly URL's locally before uploading to the server.

So I set up a test develepoment enviorment locally on Windows XP using latest version ot WAMPSERVER.

I even opened the htaccess.txt file up in an editor seleceted save all files so I could save it as .htaccess and it apeared to save it corectly but now when I access the web page locally it just cranks out a 500 internal server error.



Zorro..........
When You Change The Way You Look At Things. The Things You Look At Change....!
[www.garysnotebook.com]

Options: ReplyQuote
Re: .htaccess not working on windows
Posted by: CyberSpatium (71.237.217.---)
Date: March 10, 2007 10:37PM

windows saves the htaccess.txt, not as .htaccess. it needs to be .htaccess to work. you will need to save the file as htaccess.txt, and then right click on it and select rename and rename it to .htaccess.

if that does not work, run this batch file:

copy htaccess.txt .htaccess
del htaccess.txt



CyberSpatium
----------------------
WAMP English Forum Admin

Options: ReplyQuote
Re: .htaccess not working on windows
Posted by: zorro56 (---.tampfl.fios.verizon.net)
Date: March 13, 2007 07:43PM

Ok I tried what you recomended but that Windows XP does not allow to save the file like this. So what I did instead was open up the file and then save as all files and it apeared to save the file but now the site does not work. I get the following error.



Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator, webmaster@localhost and inform them of the time the error occurred, and anything you might have done that may have caused the error.

More information about this error may be available in the server error log.



Zorro..........
When You Change The Way You Look At Things. The Things You Look At Change....!
[www.garysnotebook.com]

Options: ReplyQuote
Re: .htaccess not working on windows
Posted by: CyberSpatium (71.237.217.---)
Date: March 13, 2007 08:23PM

save your .htaccess file as htaccess.txt

then use this batch script to change htaccesss.txt to .htaccess. to do this create a new text document and save the file as change.bat

put this code in the change.bat batch file:
copy htaccess.txt .htaccess

now save the file and put it in the same directory your htaccess.txt files are. double click on it to run it, it will now copy htaccess.txt to .htaccess

now delete the htaccess.txt file.


CyberSpatium
----------------------
WAMP English Forum Admin

Options: ReplyQuote
Re: .htaccess not working on windows
Posted by: yfastud (72.236.169.---)
Date: March 13, 2007 08:47PM

Actually, with notepad, you can save a file with any extension when saving it in double quote, for example ".htaccess" or "test.php", so on

Have fun,

BN

Options: ReplyQuote
Re: .htaccess not working on windows
Posted by: zorro56 (---.tampfl.fios.verizon.net)
Date: March 13, 2007 08:52PM

Actually the problem I am having now is not that I can not save the file as .htaccess it that once I save it I get the site does not work and I get the error I mentioned above.



Zorro..........
When You Change The Way You Look At Things. The Things You Look At Change....!
[www.garysnotebook.com]

Options: ReplyQuote


Sorry, only registered users may post in this forum.