Best way to build a WordPress site so it can be moved
# September 17, 2009 at 10:22 pm
This is my first time in the forums at CSS-Tricks but I have been following the site for a long time. A big thanks to Chris and all involved for this incredible resource.
I am reasonably new to WordPress and have decided to use it as a CMS for the redesigning of a client’s existing website. (Please don’t start a CMS vs Blog debate). I was wondering if anyone had any advice about the best way to setup wordpress so that it can be moved to the root directory of the client’s hosting once development is complete.
It doesn’t seem easy from what I have read especially with regard to way WordPress uses full URL paths to images etc.
Say my client has a live site at "www.example.com". Is it best to setup WordPress in a subdirectory like "www.example.com/temp" while I’m working on it? Then try and move the site to the root when it’s time to replace the old site and "go live’?
Surely this is a problem commonly faced. Any advice at all about the best way to build a WordPress site so that is can easily be moved to replace and existing live site would be very much appreciated.
Also I was wondering how many of you use the image uploading within WordPress and how many use you’re own FTP programs? And when you add images to pages/posts do you code it yourself or use the WordPress buttons and let WordPress code it for you? It doesn’t seem as easy as you would hope to FTP your images to a folder and insert them via a relative path.
Thanks in advance for your advice.# September 18, 2009 at 2:53 am
it actually isn’t that hard to move wordpress. You need to change the url in the admin area and you need to edit the tables manually from phpmyadmin. there are like 3 places if I remember correctly that you need to edit. You can download wamp and install that if you are using a pc. There is a mac version also. You can build the site on your puter then install wordpress on the server and change the paths in the few places they are. There are tutorials on the web on how to move wordpress. It can be done.# September 18, 2009 at 10:26 am
wamp acts just like a regular server. It comes with phpmyadmin. So when you build your website and test it, the address would be http://localhost/Your website
Google wamp tutorials. I am sure you will find a whole bunch. I use it to develop wordpress and to test themes on my computer. You can also instal nuke themes. It turnes your computer into a server.# September 18, 2009 at 10:37 am
There is some problem with the forums or is it just me? :| I posted a reply here some time back and though I thought it got posted, but it didn’t :| [And this is the 2nd time I had to face this problem :( :(]
Well, what ever I posted cyberdoc has posted it also hehe so nevermind :P
One more thing about wamp is that you won’t be able to send email’s from your localserver. It can be configured though but you have to google for the process.# September 24, 2009 at 12:43 am
Thanks very much for your advice friends!
One more related quick question:
So my client has an existing non-wordpress site that gets a about 30-50 hits a day.
I have developed a new site for them using wordpress on their hosting at the URL: http://www.clientsdomain.com/temp/. I need to move it to the root and replace the old site.
What’s the best method for doing this with minimum down time and mess? Is there a way to use a temporary "maintenance" index.php (or html) and at the same time test the site is working in the root once it’s moved? I’m sure there will be a fair bit of testing/stuffing around with changing paths in wordpress database.
I’m sure people must have this problem all the time. I’m just not sure how word a search for a solution.
THANKS!# September 24, 2009 at 12:53 am
There was an article on the web I just saw, Funny thing is that the guy who owns this website did the article. He has a digging into wordpress website. The link to the article is below. it’s saying that you don’t have to install wordpress in the public domain. You can put it in another domain. That would leave your clients website up and running while you made the change. Then when you set the final paths, everything would be ready to go with no down time unless you miss a setting somewhere. But then all the regular files would still be in place, so it would be really easy to get the site back up.
useful links# February 16, 2010 at 9:22 am
As a quick bonus tip to this thread… I MUCH prefer to develop on a subdomain rather than a subdirectory. e.g.
…is better than…
It’s just that if you hard code any links in, like <a href="/contact/">, that will actually work on the subdomain but not on the subdirectory. Not to mention image sources, links to external files, etc. You don’t want a bunch of links pointing to the wrong places just for the sake of development.
You must be logged in to reply to this topic.