. htaccess is an Apache access control file, Apache httpd.conf options with this file, the perfect implementation of the directory, site access control, of course, the most or rewrite function, that is, url rewrite, PHP implementation of pseudo-static an important way, is also recognized as SEO in search engine friendly is a very effective means.
Although the previous days of the black screen storm uproar, but according to my humble opinion, Windows users did not reduce any. One practical problem now is that Windows does not allow renaming. There are no characters in front of it, and it is considered illegal to have such a file name. This makes it impossible for us to create this access control file by renaming "new text document. txt" to ". htaccess", but there is always a workaround. And look at the following several methods:
1, the use of DOS command, under DOS There are three ways to choose:
Use the On-screen edit command to copy con. htaccess, enter the content, and finally press CTRL + Z to end the edit, the successful generation. htaccess;
Use the rename command ren 1.txt. htaccess, this is the most conventional method, in Windows window can not execute the command, under the cmd but hushed;
Use the redirect command echo. >.htaccess, where a carriage return is entered into the. htaccess, it is also possible to create a success;
Three methods are as follows:
2, with WinRAR file Manager, first create a new article document, and then open the WinRAR main interface, navigate to the file, you can rename directly, this is when I unzip a foreign open source project, Its own. Htaccess can actually extract the right out of the inspiration, of course, you use 7zip and the like manager is also possible, OK, see:
3, directly through the text editing tools to save, such as Notepad, UltraEdit and so on, but save the time to choose all the files on it, this is really a way to beat, but certainly not I owe beating, is not to beat the Microsoft, gorgeous to a:
4, using the file creation method in PHP,fopen,file_put_contents file name directly to take. htaccess.
I have found it at present (invention?) There are so many ways, but should it suffice?
n ways to freely create. htaccess files under Windows