If you rename the url of a page and need to redirect old URL to your new page, use the below given code in your htaccess page
Redirect 301 old_file_name.html http://example.com/new/file_name.html
If you rename the url of a page and need to redirect old URL to your new page, use the below given code in your htaccess page
Redirect 301 old_file_name.html http://example.com/new/file_name.html
You can set any page as a default page in a directory by adding below given code in your .htaccess file
DirectoryIndex firstpage.html
You can create custom error pages and redirect to these pages by adding the below given codes in the htaccess pages
ErrorDocument 404 /404.php
ErrorDocument 500 /500.php
ErrorDocument 401 /401.php
ErrorDocument 403 /403.php
If index file is not there in a directory, visitors can view all the files in that directory.
You can prevent this by adding a single line code (Given Below)in your .htaccess file .
Options All -Indexes