Technology Insights

How to Upload Files to a WordPress Post

After WordPress 2.5 uploading files to posts has become much easier. When first looking into this I was confused though because I every time I would upload a file it would not automatically link to the file. I was assuming the file did not upload properly and that was the reason there was no file to link to. I was mistaken though and really uploading a file is exactly like uploading an image but you have to select where the file links to. Follow the simple directions below to upload files to a WordPress post on your WP blog. The directions below are based on WordPress 2.7+ however they are very similar to WordPress 2.5/2.6.

  1. Open WordPress Admin: Obviously the first thing you need to do is login to the WP administration area of your blog which is typically found at your URL followed by /wp-admin.

Technology Insights

Change the Table Prefix of WordPress Blog MySQL Database from wp_

The directions below will provide simple instructions on changing the prefix to your WordPress blog’s MySQL database from wp_ to whatever you choose. Its a good idea to change this prefix to prevent zero-day SQL injection attacks from being performed against your WordPress installation since your database tables will be known to everyone if you use the default prefix. So follow the below directions to make the change that should only cause minimal downtime if the steps are followed properly.

  1. MySQL Database Backup:Use the CLI or backup your database from phpMyAdmin. If using phpMyAdmin use the export feature to export a SQL version of your database and download it to the PC you are working on. Your backup should be something similar to mydb_DATE.sql.

Technology Insights

Remove the Website Field For Comment Posting on WordPress Using Mandingo Theme

In an attempt to promote as much community as possible I would suggest removing the Website field for when people post comments to your WordPress blog. In this scenario below the Mandingo Theme is being used however it is just as easy to remove the Website field from the default field as well. If people still want to post their web site when making a comment they can do so in the body of the comment.

If you are using the Mandingo Theme then you will need to modify two files but if using the default WordPress Theme you should only need to modify one file. The lines to remove should be the same or very similar no matter what Theme you are using.

In Mandingo follow the below directions to remove the Website field from the comments form when people are not logged in.

Technology Insights

How to Update WordPress Blog URL

Below are a couple simple steps to update your WordPress blog’s URL. The below is valid if you are simply switching the URL using the same domain or if you are changing the WordPress domain all together. You will run into problems if you do not make sure to update each item.

  1. Update WordPress SiteURL: In the database table wp_options make sure to change siteurl to the new URL. This should be the first row in the wp_options table.
  2. Change Blog Address: Under “Settings” and then “General” change the “Blog Address” to the new URL.