Say I have like 100 pages that I am no longer using and I want to redirect them all to my homepage.
Can I do that without having 100 Redirect lines in .htaccess?
Ideally I would like something that says "if URL is not in sitemap.xml, then 301 redirect to www.domain.com"
Is there a way to do that or do I need 100 Redirect lines?
Yeah it’s WordPress. What do you mean "just program it into wp"? Is there a redirect option/menu somewhere?
WP is installed in the root directory.
So like say I have an older page that used to be domain.com/category/whatever. I no longer have that anymore so I just want it to redirect to domain.com. There are like 100 of those pages that need to be redirected. If there were only 5 I would just put them as individual lines in .htaccess like this:
Redirect /olddirectory/oldfile.html http://yoursite.com/
But I don’t wanna do that 100 times, plus I hear that too much stuff in .htaccess can slow down the site or something.
That looks like I have to manually enter each page I want to redirect. is having a huge list of 100 pages going to slow down my site or overload the server or anything?
Just going off of what I read somewhere
So I should use that plugin listed above and add the 100 URLs to that rather than adding the 100 URLs to .htaccess?
I found this plugin which does what I want. Any 404 page gets redirected to the homepage.
That’s exactly what I asked for.
I wanted to redirect a bunch of pages that were no longer being used to the home page. I didn’t want to list them individually in 100 lines of code in .htaccess.
That plugin redirects any 404 page (including the 100 that I am no longer using) to the homepage.
I’m not that good at this stuff so I didn’t think about just redirecting all 404s.
I mean, I knew all the unused pages were going to become 404s, but for some reason I never thought about redirecting them that way.
Anyway I got it working the way I want now so it’s all good.
Say I have like 100 pages that I am no longer using and I want to redirect them all to my homepage.
Can I do that without having 100 Redirect lines in .htaccess?
Ideally I would like something that says "if URL is not in sitemap.xml, then 301 redirect to www.domain.com"
Is there a way to do that or do I need 100 Redirect lines?
Yeah it’s WordPress. What do you mean "just program it into wp"? Is there a redirect option/menu somewhere?
WP is installed in the root directory.
So like say I have an older page that used to be domain.com/category/whatever. I no longer have that anymore so I just want it to redirect to domain.com. There are like 100 of those pages that need to be redirected. If there were only 5 I would just put them as individual lines in .htaccess like this:
Redirect /olddirectory/oldfile.html http://yoursite.com/
But I don’t wanna do that 100 times, plus I hear that too much stuff in .htaccess can slow down the site or something.
That looks like I have to manually enter each page I want to redirect. is having a huge list of 100 pages going to slow down my site or overload the server or anything?
Just going off of what I read somewhere
So I should use that plugin listed above and add the 100 URLs to that rather than adding the 100 URLs to .htaccess?
I found this plugin which does what I want. Any 404 page gets redirected to the homepage.
That’s exactly what I asked for.
I wanted to redirect a bunch of pages that were no longer being used to the home page. I didn’t want to list them individually in 100 lines of code in .htaccess.
That plugin redirects any 404 page (including the 100 that I am no longer using) to the homepage.
I’m not that good at this stuff so I didn’t think about just redirecting all 404s.
I mean, I knew all the unused pages were going to become 404s, but for some reason I never thought about redirecting them that way.
Anyway I got it working the way I want now so it’s all good.