Archive for the 'Wordpress' Category

The Easier Way to Move A Wordpress Blog to a New Host

The other day, I wrote about how you can move your wordpress blog to a different server/host.

Although moving your database and files is quite a foolproof way to move your script, a couple of my friends reckoned that they’d rather stay away from databases. Although phpMyAdmin is a GUI based solution, people’d rather not mess with databases at all if they could help it. Furthermore, manually moving all the files could be time consuming if you have a slow connection at home.

That is why I decided to publish this post which shows an easier way to do the same without the hassle of meddling with phpMyAdmin.

This uses the export feature provided in the wordpress dashboard.

So here’s how you move to a new host in 2 mins:

1. Login to your wordpress blog/site

2. Click on the Manage Tab and Select “Export”. Select all authors and Download the Export File.

3. Save the .xml file on your localhost. You’ll need this later when you export it back to the new server.

4. Note down your permalink, plugin and theme settings. You’ll have to manually reset them in the newer installation.

Permalink Settings

Permalink Settings

5. The export is now complete. Head off to your domain registrar and change the DNS settings to the one provided by the new host.

6. Open cPanel on the new host and create the addon domain. Use the 5 minute install <link here> or fantastico to install a new version of Wordpress.

7. Login and head off to the “Manage” tab. Select “import” and upload the .xml file that you downloaded in step 2.

8. Now you will have imported all your posts and comments to the new location. Time to tweak a few settings to make it look completely like the older version.

9. Delete the default “Hello World post”. Change the permalink settings to match those you noted in step 4.

10. You’ll also want to upload the previously used plugins to the wp-plugins folder. Upload your old theme to the wp-content folder and select it.

11. Move the wp-uploads folder.

12. Voila, your wordpress installation is complete. Your new blog looks exactly like the old one.

How To Move a Wordpress blog to a New Host

This is the Wordpress logo. Why are you pointing at it?

I recently changed my webhosting provider. Hence, I had to move all my sites from the old host to the new one. Doing this with static HTML/CSS sites is simple enough. But for a database backed script like wordpress it can turn out to be quite tricky.

I’ve heard this question being asked quite often by friends on Personal Messenger and on webmaster forums. That is why I made a step-by-step tutorial on how it is done.

1. Find out the name of the MySql database you’re using for the wordpress blog. Download this database to your localhost. If your host offers cPanel, then you can use phpMyAdmin to do this.

2. Open phpMyAdmin. Select the name of your database. Click on the “export” tab. Select all. Export them as an SQL file and save it on your PC.

3. Copy all the wordpress files and save them on your localhost. This includes all the files and folders in the directory for your domain. So you should have a bunch of files, and the wp-admin, wp-includes and wp-content directories. The image makes it clear:

4. Now change the DNS settings for your domain and point it to the nameservers of your new web host.

5. Create an addon domain (if required) with the new host and copy all the files and folders from your previous installation. Move the folders as they are. They should include the files and folders showing in the image above.

6. Now it is time to work with databases. Create a new MySql database and assign a user to it. You can do this easily from cPanel.

7. Open up the wp-config.php file from the root directory of your domain/blog. Edit the name of the database, username and password to match the new ones you just created in step 6.

8. Remember the database you downloaded way back in step 1? Time for it to be uploaded to the new server/host. Open up phpMyAdmin. Select the name of the new database you created for wordpress and click on the import tab.

This is the phpMyAdmin import tab

9. Browse to the saved .sql databse and click on Go to upload it.

10. Voila! You have moved your wordpress blog to a new host!

This may take some time, but it is the most fool-proof way to move your wordpress sites/blogs to a new hosting provider/server.

The easiest way to optimize your websites for search engines - Wordpress plugin

You’ve probably read(and experienced) a lot on how Google penalizes websites/blogs for duplicate content.

Whats that? You say your content is 100% unique and home-made? Well, thats not the utter and complete truth, because google indexes your content from http://yoursite.com and http://www.yoursite.com, effectively crawling your blog/website twice. This also dilutes the effectiveness or incoming links as some may point to the www version and others to the non-www version of your website.

Now you might think that the Googlebot isnt so dumb, and it isnt, but all the same its best to fix the problem.

Thats where the enforce www plugin comes in. From the page:


This plugin will help preserve your permalinks by enforcing your no-www or yes-www preference (http://example.com/ vs. http://www.example.com/) and will strip off index.php from the ends of URLs.

Once you’ve installed the plugin, set up your preference for your domain from Options->General tab on your Wordpress admin menu, and thats all there is.

Wordpress Options

I use the non-www preference for Shypy.com, so even though you type in www.shypy.com in your browser, it always takes you to http://shypy.com (no WWW!) ;)
No WWW!

Edit: The same effect can be achieved by doing a .htaccess rewrite - more info can be found here

An easy way to use images in your blog posts - ImageShack WordPress Plugin

Using Images spruces up you blog posts. Period.

This has been said again and again, so I’m going to show you a little trick(read plugin) which I use to use images with my blog posts and save hosting disk space at the same time.

If you dont already know, it is more convenient to use an Image Host for uploading images, rather than upload it to your own server.

ImageShack and TinyPic are the most reliable ones, and the ones I use. But the problem is that everytime you want to upload an image, you need to go to their webiste, upload it, and use the link in your blog post.

Thats where the ImageShack Uploader plugin by Arne Brachhold can make things a lot more convenient.

You can download it by clicking here.

After downloading it, upload it to your wp-content/plugins directory and activate it.

After activating it, an ImageShack tab will appear next to the Upload tag at the bottom of

WP post editor. You can now upload files from your editor itself without opening a new browser tab/window.

ImageShack

You’ll get several optios after uploading the image:

ImageShack plugin

You can upload multiple images and use them as and how you want to.

PS: You can also use the edit image toolbar button in WP to change the alt tag, adjust alignment, etc.