For .htaccess, read the definitions here:
http://www.google.com/search?q=defin...ient=firefox-a
.htaccess can be used for:
* mod_rerwite - whe rewriting URLS, making them search engine friendly
* 301 permanent redirect - forwarding or redirecting from one domain to another (can also be used to redirect your 'non-www' to a 'www')
* Error documents like the 404 error
* blocking IPs
* disallowing visitors from viewing certain pages of your site