Redirect Issues after WordPress 3.1 Update

February 24th, 2011

If your site is performing an infinite redirect after the wordpress 3.1 update, you can install the following plugin to remedy the issue:

http://wordpress.org/extend/plugins/permalink-fix-disable-canonical-redirects-pack/

You should still have access the the wordpress admin panel to activate this plugin

I believe wordpress will be taking care of this issue upon their next package release.

Changing WordPress Site and Blog URL’s

November 4th, 2009

On your wordpress blog admin panel through “Settings” > “General” you have the capability of updating your blog urls. One common mistake that many people make is updating these urls to addresses that do not point to their blog and in turn cause the blog to not resolve properly. If this happens to you, you can update the urls on the database either by logging into the database server directly or by using phpmyadmin. To do so you can run this simple query:

mysql> update wp_options set option_value = ‘http://yourblogdomain.com’ where option_name = ‘home’ or option_name = ’siteurl’;

Delete All WordPress Comments Awaiting Moderation

April 11th, 2009

To delete all wordpress comments awaiting moderation you can run the following:

DELETE FROM wp_comments WHERE comment_approved=’0′;

(be sure to make a backup of your blog database prior to doing so just to be safe)

Manually update wordpress admin password

April 2nd, 2009

Lost your password? Forgot your password link not working? well you can just reset it using a simple mysql query:

UPDATE wp_users Set user_pass =”passsword” WHERE ID = 1;

(Note: the ID integer reflects the ID of the user you want to modify the password for, so be sure to check your database to see what ID matches up to what user)

You can run the above command via shell or through phpmyadmin.

Upgrading WordPress Blog

April 2nd, 2009

So you’ve decided to upgrade your wordpress blog. There are a few ways you can do this:

1) Use the automatic upgrade tool included with wordpress 2.7.x

2) Use an upgrade plugin

3) Manually upgrade your wordpress blog

I will now go through the three procedures below:

(Note: it is very important to make backups of your wordpress files and database before proceeding with any upgrade, as upgrading a blog can effect your themes, plugins, etc. Having a backup will let you revert  your blog to its previous state if the upgrade does not go as smoothly as planned)

1) Automatic Upgrade Tool (WordPress 2.7.x)

With the release of wordpress 2.7.x an upgrade tool is now included with the wordpress package. When new packages are available, wordpress will give you a prompt on the top of your dash board when you log in. To upgrade, simply click “Upgrade Now.” You will then have the option of either automatically upgrading the blog or downloading the files to run the upgrade manually ; I will go over the manual upgrade later on in this post.  At this point, select the automatic upgrade option, watch the script run, and you should be good to go. You may however run into a few common issues:

a)Safe mode is not turned off

If safe mode is on, the upgrade will not run so be sure to have this set to off. You can typically modify this setting on your php.ini file. The directive looks like this:

safe_mode = off

If you do not have write access to this file, contact your web host and ask them to turn this off for you. If you’re weary of making this change, you can always switch safe mode back to “On” when you have completed the upgrade.

b)wp-header.php is unwritable

If the wp-header.php file is unwritable you’ll get a nice error telling you off this, simple ensure that you have the proper write permissions to this file and you should be good to go.

c) Upgrade will not run due to a memory issue

PHP memory is limited on some hosting companies and you may or may not have enough allocated memory set to preform the upgrade. If you require more php memory, you can update your php.in file and adjust the following setting:

memory_limit = 18M

(from my personal experience upgrades tend to utilize anywhere from 18-20M so set this value at a comfortable number so you do not go over the limit)

2) Upgrade Plugin

There are several plugins that you can install to automatically upgrade you blog. I would suggest searching for one online. Just install the plugin and activate it through the Plugin settings on your wordpress admin panel. This is only for users who have versions of wordpress prior to 2.7.x installed as newer versions of wordpress have the auto upgrader and having both can cause conflict issues. The same measures noted below for automatically upgrading apply here as well. Make sure that safe mode is off, that you have sufficient php memory, and that you have the proper permissions to overwrite existing files.

3) Manual Upgrade

Manual blog upgrades are a lot simpler than how it sounds. All you really have to do is obtain the latest package of the wordpress files and upload the files over your existing wordpress files.

You can obtain the wordpress packages from two places:

a) If you’re using wordpress version 2.7.x you can download the latest package through the automatic upgrade tool as it provides you have an option to download the files

b) Through the wordpress.org site you can also obtain packages of wordpress here is the url:

http://wordpress.org/download/

After obtaining the package, upload it via ftp and overwrite your existing wordpress files.  Then access your admin panel to via webbrowser to finalize the upgrade.

Also keep in mind for php safe mode, php memory, and permissions

WordPress displays blank white page

March 31st, 2009

There are several reasons why your wordpress blog displays nothing but a blank white page. I am only however going to go through the two common causes:

1) So you’ve attempted to upgrade your blog and in turn you get a blank white page. Check for the following:

- Safe Mode is turned Off
- Check to see if wordpress is waiting for you to finalize your  upgrade by going to admin panel  and then finalizing your upgrade.
- See if you have enough PHP memory to run the installation, upgrades typically require 18-20MB, your webhost may have this set to a lower value for performance optimization purposes.

2) So you’ve enabled a plugin and your blog now displays a blank page. Check the following:

- Safe Mode is turned Off
- See if you have enough PHP memory to run the plugin, plugin memory requirements vary depending on the plugin

If you are unable to remedy the problem with the solutions above,  then I would suggest looking into the error logs to determine the root cause of the problem. You may or may not have access to this.

Permalinks: "I enabled Permalinks and now I have a 500 error"

March 31st, 2009

Permalinks require mod rewrite and  rewrite engine enabled on your site. So if you update your permalinks without verifying that rewrite engine and mod rewrite are enabled,  then you’ll likely run into a pretty 500 internal server error. To remedy this, you have to enable mod rewrite with the rewrite engine directive on your webserver.

WordPress Blog File Uploads, "My Images Do Not Display"

March 31st, 2009

So you’ve uploaded images on your wordpress admin panel and they do not display on the uploader and you are unable to insert them into posts.  Have you checked your uploads directory settings under your WordPress Blog Settings? The fix typically for this issue is to set your wp-uploads directory to wp-content/uploads which can be found through the following path on the wordpress admin panel:

“Settings” > “Micellaneous”

make sure that it’s set as ‘wp-content/uploads‘.

WordPress generally looks for images within the uploads directory so if your uploads directory is set elsewhere, then your images and files will not display.

What if your  upload directory is already set to ‘wp-content/uploads’?

If this  is the case I would suggest ensuring that the uploads directory exists and has the proper permissions to allow write access.  You can apply 755 permissions to your uploads directory (you can use other permissions as well, this is just a suggestion)

What If the directory exists and has the proper permissions and my uploads still do not work?

Make sure that file uploads is enabled for your blog.  If you have access to your php.ini file, you can check to see if file uploads is enabled and that the proper upload temp directory is set for your site.

The two settings to look for would be:

file_uploads = On (make sure this is set to on)
upload_tmp_dir = (this should be set to whatever your tmp directory is on the server)

Migrating WordPress Blog To Another Host

March 31st, 2009

If you’re planning to migrate your blog between hosts, there’s a few things you would need to make it a simple process:

1) wordpress blog database backup

your wordpress database contains your posts, users, and various settings. If you want to bring all of these with you to another host provider, it is essential that you obtain a backup of your blog database. If you do not have access to creating a backup yourself , your hosting company’s tech support should be able to provide you with a copy.

2) Your wordpress files

Essentially, you would only need the wp-content folder as it contains your themes, plugins, uploads, and widgets that you may want bring with you.  You will however need to download and unzip a wordpress package on the new server if you only decide to transfer your wp-content folder over.

(NOTE: If you plan on just bringing your posts over you can just export an xml containing all of your posts and import them into the new blog account)

With your blog database backup and wordpress files handy,  you can then upload your wordpress files onto the new webserver and then restore the backup of your database. You will then be required to update your wp-config.php file so that your blog can connect to your blog database. You would just need to update the db host, db name, db user, db user password to match your database.

After completing the steps above, you should be able to connect to your blog via web browser. You can then log into your blog admin panel and activate your theme, plugins, widgist, and permalinks to your preferred  settings and you’re all set.