some .htaccess help?
I'm trying to learn htaccess, but I'm having issues wrapping my head around this. I need to learn by example. Have several types of 301 permanent redirects that are needed.Want to redirect a single page to a new page
OLD - http://www.domain.com/page.html
NEW - http://www.domain.com/newfolder/page.html
Want to redirect a folder, AND any pages in it (preferably without naming EACH page), to a new folder's index
OLD - http://www.domain.com/oldfolder/lots-of-html-pages
NEW - httr://www.domain.com/newfolder/index.html
Want to redirect a subdomain to the primary domain
OLD - http://web.domain.com
NEW - http://www.domain.com
Want to redirect a folder, AND any pages in it, to a new subdomain
OLD - http://www.domain.com/folder/pages.html
NEW - http://newsite.domain.com/folder/pages.html
Using ISAPI_Rewrite 3 on 2003/IIS6, which uses htaccess commands.
Could anybody here show me what they would do in these scenarios?
I've read and read, and tried and tried, but it never seems to work out correctly. It either fails to redirect, or it redirects too much (some "open" type commands with a lot of variables will pick up the keyword -- for example, "students" -- so students.domain.com AND domain.com/students AND domain.com/program/students.html would all redirect, even though I only wanted the subdomain version, or the page version, to redirect, and not the others!).
Thanks for reading. More thanks for your suggestions.
