Htaccess
Creating a .htaccess file may cause you a few problems. Writing the file is easy, you just need enter the appropriate code into a text editor (like notepad). You may run into problems with saving the file. Because .htaccess is a strange file name (the file actually has no name but a 8 letter file extension) it may not be accepted on certain systems (e.g. Windows 3.1). With most operating systems, though, all you need to do is to save the file by entering the name as:
".htaccess"
(including the quotes). If this doesn't work, you will need to name it something else (e.g. htaccess.txt) and then upload it to the server. Once you have uploaded the file you can then rename it using an FTP program.
Start like this:
You can use custom error pages for any error as long as you know its number (like 404 for page not found) by adding the following to your .htaccess file:
ErrorDocument errornumber /file.html /*optional
To denyl all :RewriteEngine On .....this is line should be
there in all htaccess file.
eg:
ErrorDocument errornumber /file.htmlRewriteEngine On
RewriteRule ^article/([0-9]+)/? article.php&article=$1[R]
.htaccess file to stop the directory list from being shown:
Options -indexes
You can block an IP address by using:
deny from 000.000.000.000
To allow :
allow from 000.000.000.000
deny from all