Simple Machines Community Forum

SMF Support => SMF 2.0.x Support => Topic started by: rishab555555 on July 20, 2011, 06:06:06 AM

Title: how 2 move my forum from root to subdirectory but redirecting links , what 2 do
Post by: rishab555555 on July 20, 2011, 06:06:06 AM
Hello friends , i have installed my forum in root directory , www.heyrtu.com  3 months ago . Right now i have too many links in search engines and social networks.

I want to move it to www.heyrtu.com/forum and don't want to break all the previous links.  I know this can be done by some re-directing process but dont have a clear idea.


Please help me in this process
Title: What will i lose if i do a fresh smf install with my current database ?
Post by: rishab555555 on July 20, 2011, 04:28:46 PM
I want to move my forum to /forum directory and install wordpress to root. Can you please tell me what are the possible ways ?

Moving files or a fresh install with my current 3 month old database>???


If Moving files then how shall i do that and if fresh install , what content , link or other things can i loose?
Title: Re: What will i lose if i do a fresh smf install with my current database ?
Post by: vbgamer45 on July 20, 2011, 04:30:01 PM
Just move all your files to that folder
Then run the repair settings tool.
.What is repair_settings.php? (http://wiki.simplemachines.org/smf/Repair_settings.php)

Title: Re: What will i lose if i do a fresh smf install with my current database ?
Post by: rishab555555 on July 20, 2011, 04:53:41 PM
Okay thanks...what about urls ???

I have so more then thousand urls....how shall i prevent them from breaking...can you tell me the redirect thing >>>??
Title: Re: What will i lose if i do a fresh smf install with my current database ?
Post by: Illori on July 20, 2011, 04:58:38 PM
google a 301 redirect
Title: Re: What will i lose if i do a fresh smf install with my current database ?
Post by: rishab555555 on July 20, 2011, 05:09:16 PM
Quote from: Illori on July 20, 2011, 04:58:38 PM
google a 301 redirect

Okay i read that @

Do you want to say that i have to redirect each and every url separately ??????????????????????????????????????????????
Title: Re: What will i lose if i do a fresh smf install with my current database ?
Post by: Illori on July 20, 2011, 05:11:18 PM
no you redirect the index.php url or the domain itself and it will take care of everything else.
Title: Re: What will i lose if i do a fresh smf install with my current database ?
Post by: rishab555555 on July 20, 2011, 05:14:47 PM
Quote from: Illori on July 20, 2011, 05:11:18 PM
no you redirect the index.php url or the domain itself and it will take care of everything else.


I can not redirect the Domain as i have to install wordpress in that , in that case my visitors will again be directed to the forum but i need them to see wordpress site.

Can you please specify which index.php file ?????

Of my template or in the root ??? Just tell me the correct path of it !
Title: Re: What will i lose if i do a fresh smf install with my current database ?
Post by: Illori on July 20, 2011, 05:18:37 PM
if you are installing something else in the place of the forum you cant really do a redirect as it would send the traffic to the new location.
Title: Re: What will i lose if i do a fresh smf install with my current database ?
Post by: rishab555555 on July 20, 2011, 05:22:45 PM
http://www.simplemachines.org/community/index.php?topic=440822.msg3097157#msg3097157 (http://www.simplemachines.org/community/index.php?topic=440822.msg3097157#msg3097157)


Watch the link , this person has got the thing working :(


Can i do a fresh install of smf while retaining all the posts and members ?
Title: Re: What will i lose if i do a fresh smf install with my current database ?
Post by: Illori on July 20, 2011, 05:24:44 PM
that thread does not say they were successful or how exactly they did it, and i dont think they will be successful in anyway.
Title: Re: What will i lose if i do a fresh smf install with my current database ?
Post by: rishab555555 on July 20, 2011, 05:30:22 PM
Quote from: Illori on July 20, 2011, 05:24:44 PM
that thread does not say they were successful or how exactly they did it, and i dont think they will be successful in anyway.

You should have visited the link i gave you and search that . The thing had worked and the guy was succesful in doing that !

http://www.clinicalresearchsociety.org/forum/career-discussions/launch-of-clinical-research-forum-jobs-portal/ (http://www.clinicalresearchsociety.org/forum/career-discussions/launch-of-clinical-research-forum-jobs-portal/)


The topic created is of july 03, 2011 and he has posts of 2008 in the forum !

Also forum is on the /forum directory then how can you say that
Quotei dont think they will be successful in anyway.
Title: Re: What will i lose if i do a fresh smf install with my current database ?
Post by: Illori on July 20, 2011, 05:39:02 PM
that does not mean the redirect really is working along with wp being installed there.
Title: Re: What will i lose if i do a fresh smf install with my current database ?
Post by: rishab555555 on July 20, 2011, 05:45:13 PM

http://www.clinicalresearchsociety.org/forum/index.php?wwwRedirect



What does that wwwredirect then mean>>
Title: Re: What will i lose if i do a fresh smf install with my current database ?
Post by: Illori on July 20, 2011, 05:54:55 PM
Quote from: Illori on December 03, 2010, 01:08:57 PM
Quote from: Illori on December 02, 2010, 12:48:38 PM
some searching on this forum lead to http://www.simplemachines.org/community/index.php?topic=312299.0
Title: Re: What will i lose if i do a fresh smf install with my current database ?
Post by: Illori on July 20, 2011, 05:56:00 PM
please stick to one thread on each issue, i have removed your other thread on the redirect
Title: Re: What will i lose if i do a fresh smf install with my current database ?
Post by: rishab555555 on July 20, 2011, 05:59:37 PM
Okay but my problem is still not resolved.Please look for it if you can ! I will get back here after 3-4 hours :(


Thnks
Title: Re: how 2 move my forum from root to subdirectory but redirecting links , what 2 do
Post by: shadow82x on July 21, 2011, 01:27:03 PM
I'm no SEO expert but I think a 301 redirect should do the trick just fine. And since your links will be in a similar structure, search engines shouldn't have any major issues indexing them.

But do you plan on adding files and content in your root at heyrtu.com?
Title: Re: how 2 move my forum from root to subdirectory but redirecting links , what 2 do
Post by: rishab555555 on July 21, 2011, 01:46:32 PM
That is the main thing , i want to install wordpress in the root and then want hey rtu to be bridged with it . 

If i redirect the domain , the condition will again be same :(

I want www.heyrtu.com to show wordpress and www.heyrtu.com/forum  to show smf !


Is that possible , please tell me ?
Title: Re: how 2 move my forum from root to subdirectory but redirecting links , what 2 do
Post by: Illori on July 21, 2011, 01:47:04 PM
please stick to one thread on each issue 2 threads have been merged
Title: Re: how 2 move my forum from root to subdirectory but redirecting links , what 2 do
Post by: rishab555555 on July 21, 2011, 01:50:24 PM
If you can't help then let others help please.You should have deleted the one in which you were replying !


If some one was trying to solve my problem then why did you merged them ?

I hope they will be able to find the topic :(
Title: Re: how 2 move my forum from root to subdirectory but redirecting links , what 2 do
Post by: Illori on July 21, 2011, 01:51:52 PM
they can find it in their post history. we have a policy here for a reason and people that dont stick to it will have to deal with the results.
Title: Re: how 2 move my forum from root to subdirectory but redirecting links , what 2 do
Post by: rishab555555 on July 21, 2011, 01:55:21 PM
hmmmmmm.... ok
Title: Re: how 2 move my forum from root to subdirectory but redirecting links , what 2 do
Post by: blind564 on July 21, 2011, 04:39:17 PM
Hi rishab555555.

i saw that you move your forum to subdirectory, i'm trying do this but  when i remove the files of the original directory, my forum lost tthe style.

my question is if you has tried of remove the originals files?
dont happed the same?
Title: Re: how 2 move my forum from root to subdirectory but redirecting links , what 2 do
Post by: rishab555555 on July 21, 2011, 05:45:08 PM
I am researching on the problems wich may arise as i can not bear downtime for my forum.

The problem which you are saying usually arises when we upgrade from one version of smf to another but in your case if you have only moved the files &  lost original layout then their can be some problem their.

You can do the same thing :

1.Just uninstall your custom theme
2.Run repair_settings.php  tool http://download.simplemachines.org/index.php?thanks;filename=repair_settings.php (http://download.simplemachines.org/index.php?thanks;filename=repair_settings.php)

3.If even after doing this you could not get back your right layout , just uninstall the modes and run large upgrade package and after that apply repair_settings.php

4.If everything seems fine , install custom theme again and , your forum is back again !
Title: Re: how 2 move my forum from root to subdirectory but redirecting links , what 2 do
Post by: MrPhil on July 21, 2011, 09:56:45 PM
So you want to move your SMF to a subdirectory, and know how to move the files and run repair_settings.php to adjust internal settings to the new location. The problem then becomes how to deal with all those URLs trying to access the old (root) location? As you've noted, a simple redirect to the new location (whether silently or 301) will mess up WP. Can you find all patterns in SMF URIs that are not found in WP, and vice-versa, and use those patterns to select which URIs to redirect? For example, does a WP URI include topic=nnnnnn.nn? Naturally, you'd have to find all the patterns that SMF uses and ensure that WP isn't using any of them too. If you can't, about all you could do is modify WP to bail out if it gets an incorrect URI or parameters and toss the URL over the wall to SMF. It would not be easy.

By the way, it will be a mistake to install WP in the root. It too should go in its own subdirectory. Major subsystems (SMF, WP, a store, a gallery, etc.) should always be installed in their own subtrees so that they don't interfere with each other, and can be added, removed, or changed without fear of stomping on each other. As you already have SMF in the root, if you don't want to move it, why not install WP into a subdirectory? Or, best of all, move SMF (with root-level redirection that excludes WP) to its subdirectory, install WP into its subdirectory, and put a landing page in the root that includes links to either application.

/  index.php landing page
   .htaccess to redirect /* to /forum/* (except if /forum, /blog, /index.php, or just /)
   /forum   SMF moved here
   /blog  WP installed here
Title: Re: how 2 move my forum from root to subdirectory but redirecting links , what 2 do
Post by: luuuciano on July 21, 2011, 10:26:21 PM
Do you have important content in the "old" place?
I have used this .htaccess directive when moving a forum (it was a from a directory to another domain, you will have to workit to your needs)

RewriteCond %{HTTP_HOST} ^.*$
RewriteRule ^directory\/?(.*)$ "http\:\/\/yourdomain\.com\/$1" [R=301,L]

it is cool because it redirects automagically to the newer location, no 404, errors, etc (and using a 301 for robots)
Title: Re: how 2 move my forum from root to subdirectory but redirecting links , what 2 do
Post by: Illori on July 24, 2011, 11:02:37 AM
Please stop posting multiple threads on this same issue. one thread is enough if someone knows the answer they will reply here.