Tech Question: Moving Wordpress from one Directory to Another

10 replies
I am taking over a site for a client that someone else started. The "other" person installed WP in a folder called "blog". Along with the WP install, they installed S2Member.

My question is, how difficult is it to move everything to the main directory so that we have www . domainname . com instead of www. domainname . com/blog

Right now there isnt anything there for posts except what looks like test stuff. I know I can just uninstall and then reinstall the way I want, but I am concerned about the S2Member stuff not going with it.

Any help would be cool,

Thanks,
keith
#directory #donkey #moving #question #tech #wordpress
  • Profile picture of the author tpw
    The moving is easy. Just use FTP or your cPanel File Manager to orchestrate the move...

    The hard part is configuring everything after the move...

    Inside WordPress, Just go to Settings - General to make the changes...

    Unfortunately, I have never used S2Member, so I cannot predict how hard it will be to fix its configuration settings...
    Signature
    Bill Platt, Oklahoma USA, PlattPublishing.com
    Publish Coloring Books for Profit (WSOTD 7-30-2015)
    {{ DiscussionBoard.errors[2635876].message }}
  • Profile picture of the author theentry
    As tpw said moving the files will be easy, however moving the other stuff could be tricky.
    First I would change the url in the General Setting as tpw said.
    If you are using permalinks then the .htaccess file needs to be corrected also.
    And to make sure everything is fine, I would login to phpmyadmin (sql db) and just do a search for the URL if it pops out somewhere.
    Signature
    Nifty Stats - the best free software to track your progress
    at multiple affiliate programs within one interface. Give it a try!
    {{ DiscussionBoard.errors[2635892].message }}
    • Profile picture of the author Tim Franklin
      Originally Posted by theentry View Post

      As tpw said moving the files will be easy, however moving the other stuff could be tricky.
      First I would change the url in the General Setting as tpw said.
      If you are using permalinks then the .htaccess file needs to be corrected also.
      And to make sure everything is fine, I would login to phpmyadmin (sql db) and just do a search for the URL if it pops out somewhere.
      Be very careful, I too used to think this was the way to do it, but if you look carefully at the data, you may find that at times, path/to/server is present in the data, anyway it caused me a lot of trouble when I moved a WP website a while back and thought that just because I had an SQL back up that I was good, (wrong)
      Signature
      Bitcoin | Crypto | Blockchain Secrets |
      {{ DiscussionBoard.errors[2635904].message }}
      • Profile picture of the author Harrison Ortega
        Keith, it is not necessary for you to move the Wordpress to the root directory just to use the root domain. Like myself, there are many others that hate to clutter the root directory with WP files and we just install WP using its own directory.
        Basically you just need to copy the Wordpress index page and .htaccess to the root and add some code to the index page and that's it. It is very easy to do it. It is the same thing as having the installation on the root besides the login page which still needs to be accessed using domain/blog/wp-login.php. But that is the only time you'll see/need the "blog" directory.

        Here are the simple steps to do that. Giving WordPress Its Own Directory WordPress Codex (you've already done step 1).
        Signature
        NJ web design / NJ Web Designer. MY Wordpress portfolio. 10 years of HTML/CSS - 6 years developing professional Wordpress websites. Currently not available for services.
        {{ DiscussionBoard.errors[2635968].message }}
      • Profile picture of the author theentry
        Originally Posted by Tim Franklin View Post

        Be very careful, I too used to think this was the way to do it, but if you look carefully at the data, you may find that at times, path/to/server is present in the data, anyway it caused me a lot of trouble when I moved a WP website a while back and thought that just because I had an SQL back up that I was good, (wrong)
        Then downloading all the files and going through (finding the url) them with a tool made for it would be the way to go. (for example Notepad++ can do that)

        But again if you haven't done much customization then just install a new WP in the directory and it will be done in less time
        Signature
        Nifty Stats - the best free software to track your progress
        at multiple affiliate programs within one interface. Give it a try!
        {{ DiscussionBoard.errors[2636041].message }}
  • Profile picture of the author Tim Franklin
    Sadly it is not an easy process, just yesterday I ran into an error, where I moved a website from its original location, public_html/someone-elses-old-server/

    That path somehow was preserved, I have no idea where, but this was like over one year ago, and so now I need to find out where that old server path is located, in the wordpress path and kill it dead.

    The point is that no matter how easy it may sound there will be some technically difficult operation that you may find hard to do, I would say that back up as much as you can and proceed with caution,

    Last week I would have sworn that website I moved, last year was fully integrated into the new server, that is until Wordpress changed the way they upload plugins.
    Signature
    Bitcoin | Crypto | Blockchain Secrets |
    {{ DiscussionBoard.errors[2635900].message }}
    • Profile picture of the author tpw
      Originally Posted by Tim Franklin View Post

      Sadly it is not an easy process, just yesterday I ran into an error, where I moved a website from its original location, public_html/someone-elses-old-server/

      That path somehow was preserved, I have no idea where, but this was like over one year ago, and so now I need to find out where that old server path is located, in the wordpress path and kill it dead.

      The point is that no matter how easy it may sound there will be some technically difficult operation that you may find hard to do, I would say that back up as much as you can and proceed with caution,

      Last week I would have sworn that website I moved, last year was fully integrated into the new server, that is until Wordpress changed the way they upload plugins.

      Check inside the wp-settings.php file
      Signature
      Bill Platt, Oklahoma USA, PlattPublishing.com
      Publish Coloring Books for Profit (WSOTD 7-30-2015)
      {{ DiscussionBoard.errors[2636127].message }}
  • Profile picture of the author Keith Boisvert
    Thanks everyone. Yeah, this could be either really easy, or difficult.

    I am thinking that it would be easier to just reinstall to where I want it. The S2Member "should" be able to be reinstalled since it is the same domain.

    I will try this afternoon and update.

    Thanks to all!!!

    keith
    {{ DiscussionBoard.errors[2635925].message }}
  • Profile picture of the author Ryah Albatros
    Yyou don't actually need to move all the files. This page from Wordpress gives you the instructions Giving WordPress Its Own Directory WordPress Codex

    I've been doing it this way for all my sites.So here's your instructions:

    1. In General Settings change your Site URL to the root mysite.com with no following directory and save the changes.

    2. Copy the index.php and .htaccess files from the yoursite.com/blog directory and paste them into the root yoursite.com where you want them to be.

    3. In a text editor open index.php and change require('./wp-blog-header.php'); to require('./blog/wp-blog-header.php');

    4. Save and upload it back to the site's root directory.

    Oops! Harrison was faster than me
    {{ DiscussionBoard.errors[2635971].message }}

Trending Topics