Welcome to WebmasterWorld Guest from 22.214.171.124
the pages that were a part of my blog were in this format, with a trailing slash at the end of the full url
this is what I added to my .htaccess so far:
deny from all
redirect 301 /blog http://www.example.com/free-graphic.htm
Since the blog no longer exists, I left the blog/ folder and an index.php inside of it, but want to delete it altogether.
I was trying to re-direct all blog traffic to one single page
The snip I have above works fine for all traffic coming from the home page of my old blog to the page specified above, but when a request comes for a specific post page,
it appends part of that old post page onto the redirected url, like so:
Is there any way I can just get the /blog folder and old indexed posts to redirect to that one page if people arrive by an old indexed post url?
In other words, I hope to have any page requested from old /blog, end up on this specific page:
I should mention that I am not very knowledgeable with .htaccess, just know enough to follow instructions.
I would greatly appreciate any advice given. Thanks!
[edited by: jdMorgan at 3:38 pm (utc) on May 9, 2008]
[edit reason] Please use example.com. [/edit]
It takes all of the stuff found after whatever you specified on the left, and appends it on the end of whatever you specified on the right.
For what you want to do, you'll need RewriteRule instead. There's plenty of prior examples here. Grab one, modify it, see how you get on, and then post your best effort back here.
I took the example:
RedirectMatch page1\.html page2.html
from the library:
and changed it like this:
RedirectMatch /blog\.php /free-graphic.htm
and it now works!
Date: Thu, 08 May 2008 02:40:52 GMT
Last-Modified: Sun, 04 May 2008 08:54:56 GMT
Made my changes and I changed the .html part to .php because that is what my blog used, hopefully I did that correctly, but it is acting like I wanted with no error, thanks a heap to both of you!