boxturt Posted December 10, 2003 Posted December 10, 2003 Here's the scenario (sort of). ... Inside folder "/my_songs" I have 10,000 html files. I just changed the 10,000 files to shtml extensions. (i bet you know the question by now.....) Is there a way to redirect all requests for /my_songs/*.html to /my_songs/*.shtml without doing it one title at a time. I never can word these correctly in computer speak. My bad and I apologize. Thanks Quote
boxturt Posted December 14, 2003 Author Posted December 14, 2003 This question is just ridiculous maybe?? Quote
Deverill Posted December 14, 2003 Posted December 14, 2003 Hi Ty, Sorry you haven't gotten an answer yet. Do all of your internal links point to .html or did they get replaced with .shtml? If the internal links are shtml then you can just leave everything alone and when index.html is not found it will look for .shtml If that doesn't work you can add a line to the .htaccess to make .shtml a valid extension. Search the forums and you'll find that. If the internal links still say .html then it's a bigger issue. You can do redirects but I don't think you want 10,000 of them! I would think there is some kind of php thing you can put in as a 404 error page that will take the original url and modify it and redirect to that but I'm not sure of this. The problem with this is that the search engines will think you are trying to cloak and they'll ban you maybe. If the search engines are an issue then you may have to bite the bullet and edit them. I am by no means an expert in this area so don't start editing until you hear from someone more authoritative! Quote
boxturt Posted December 14, 2003 Author Posted December 14, 2003 If I read you correctly one set of internal links does point to all shtml but there is no index file, so to speak. lyricsplayground.com >> xmas and that brings up a table of contents page and you'll see the shtml links. I left all the html files there because of search engines I do have : AddType text/x-server-parsed-html .html .htm but it seems not to work. Quote
TCH-Dick Posted December 14, 2003 Posted December 14, 2003 Try adding this to the .htaccess of "/my_songs" directory >RedirectMatch (.*)\.html$ $1.shtml Quote
boxturt Posted December 14, 2003 Author Posted December 14, 2003 Ok, I see how that would work -very cool indeed. Thanks. It's certainly a start. I put it in a folder to test real quick and suddenly lost 22,000 songs for a second - that was fun. I have only changed the extensions in the christmas song folder. Now even though all these songs are search engine listed as .html they will find the shtml pages., and eventually the SE will index the new SHTML and drop the old HTML? Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.