Welcome to the GoFuckYourself.com - Adult Webmaster Forum forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact us.

Post New Thread Reply

Register GFY Rules Calendar
Go Back   GoFuckYourself.com - Adult Webmaster Forum > >
Discuss what's fucking going on, and which programs are best and worst. One-time "program" announcements from "established" webmasters are allowed.

 
Thread Tools
Old 02-02-2015, 09:16 AM   #1
pimpware
Confirmed User
 
pimpware's Avatar
 
Join Date: Jan 2006
Location: Pt
Posts: 1,673
Help with the best redirecting method

Hi folks,

I could bet my question is somewhere answered but the search function is not working.

I have a domain.com wordpress blog with a couple of old sub-domains(niches), each one a wordpress blog.

It happens that I want to get rid of almost all of those sub-domain blogs, and redirect them to the main blog, and my question is what is the best redirecting method?

Thanks
__________________
icq: 284494832
realsexforyou.com
pimpware is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 02-02-2015, 09:21 AM   #2
MakeMeGrrrrowl
Grrrrrrrrr
 
MakeMeGrrrrowl's Avatar
 
Industry Role:
Join Date: Oct 2002
Location: Dreamland
Posts: 4,974
Quote:
Originally Posted by pimpware View Post
Hi folks,

I could bet my question is somewhere answered but the search function is not working.

I have a domain.com wordpress blog with a couple of old sub-domains(niches), each one a wordpress blog.

It happens that I want to get rid of almost all of those sub-domain blogs, and redirect them to the main blog, and my question is what is the best redirecting method?

Thanks
This is the one I use.

https://wordpress.org/plugins/redirection/
MakeMeGrrrrowl is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 02-02-2015, 10:31 AM   #3
Marvin_AWB
Registered User
 
Marvin_AWB's Avatar
 
Industry Role:
Join Date: Dec 2014
Posts: 62
I would set up a 301 redirect. It bascially tells the search engines: "this site moved permanently" and is the standard procedure for what you are planning to do.

You can use a WordPress plugin like Grrrrowl suggested or manually edit your .htaccess file. It's usually just a few lines of code.
__________________
AdultWebmasterBlog.com - Tips, tricks and tutorials for adult webmasters.
Marvin_AWB is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 02-02-2015, 10:40 AM   #4
pimpware
Confirmed User
 
pimpware's Avatar
 
Join Date: Jan 2006
Location: Pt
Posts: 1,673
Quote:
Originally Posted by MakeMeGrrrrowl View Post
MakeMeGrrrrowl thanks for your sugestion, that plugin looks pretty good but at this time I want to keep the plugin numbers at minimum for performance reasons.


Quote:
Originally Posted by Marvin_AWB View Post
I would set up a 301 redirect. It bascially tells the search engines: "this site moved permanently" and is the standard procedure for what you are planning to do.

You can use a WordPress plugin like Grrrrowl suggested or manually edit your .htaccess file. It's usually just a few lines of code.
Setting up a 301 redirect with my .htaccess file would allow me to delete all stuff related with those blogs, even the sub-domains? Or do I have to keep the sub-domains active?

Thanks
__________________
icq: 284494832
realsexforyou.com
pimpware is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 02-02-2015, 10:45 AM   #5
suesheboy
Confirmed User
 
suesheboy's Avatar
 
Industry Role:
Join Date: Nov 2002
Location: FL - TN/NC
Posts: 5,211
.htaccess for the win.

I have made a htaccess redirect each sub domain by having a htaccess file in each sub domain.
suesheboy is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 02-02-2015, 11:16 AM   #6
Marvin_AWB
Registered User
 
Marvin_AWB's Avatar
 
Industry Role:
Join Date: Dec 2014
Posts: 62
Quote:
Originally Posted by pimpware View Post
Setting up a 301 redirect with my .htaccess file would allow me to delete all stuff related with those blogs, even the sub-domains? Or do I have to keep the sub-domains active?
No, you don't have to keep them active.

Just a quick example:

RewriteEngine On
RewriteBase /
RewriteCond %{HTTP_HOST} !^mydomain.com$ [NC]
RewriteRule ^(.*)$ http://mydomain.com/$1 [L,R=301]

This code would check that the address the visitor wants to access starts with mydomain.com. If not, let's say because the visitor wants to access mysubdomain.mydomain.com, there will be a 301 redirect to the main domain (mydomain.com).

This means no matter which sub-domains the visitor wants to accesss, there will always be a redirect to the main domain. Therefore, it doesn't matter if the sub-domains are active or not.

This solution is "quick and dirty" and only makes sense when you don't want to have new sub-domains in the future.
__________________
AdultWebmasterBlog.com - Tips, tricks and tutorials for adult webmasters.
Marvin_AWB is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 02-02-2015, 11:17 AM   #7
Paz
Confirmed User
 
Paz's Avatar
 
Industry Role:
Join Date: Jun 2012
Posts: 457
Actually the htaccess will probably put a greater strain on a busy server because every js, css, gif, jpg etc file will be processed by the htaccess file where as the plugin will probably be a lot more targeted.

If you do go down the htaccess route I would leave the sub-domains up and empty apart from your htaccess but you could put everything on the main site and delete the sub-domains (as per AWB's suggestion above ).

If you have a dedicated box or a VPS (ie you're not on shared) you have other options such as setiing up redirects in Apache, also I have an idea I did something similar via CPanel and it might be worth looking there too.
Paz is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 02-02-2015, 11:55 AM   #8
pimpware
Confirmed User
 
pimpware's Avatar
 
Join Date: Jan 2006
Location: Pt
Posts: 1,673
Quote:
Originally Posted by Marvin_AWB View Post
No, you don't have to keep them active.

Just a quick example:

RewriteEngine On
RewriteBase /
RewriteCond %{HTTP_HOST} !^mydomain.com$ [NC]
RewriteRule ^(.*)$ http://mydomain.com/$1 [L,R=301]
This code allow me to add some kind of exception? I want to redirect all but 3 existing sub-domains.
__________________
icq: 284494832
realsexforyou.com
pimpware is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Post New Thread Reply
Go Back   GoFuckYourself.com - Adult Webmaster Forum > >

Bookmarks

Tags
blog, question, wordpress, method, redirecting, rid, main, redirect, sub-domain, blogs, search, function, answered, folks, sub-domainsniches, bet, couple, domain.com



Advertising inquiries - marketing at gfy dot com

Contact Admin - Advertise - GFY Rules - Top

©2000-, AI Media Network Inc



Powered by vBulletin
Copyright © 2000- Jelsoft Enterprises Limited.