Need a WordPress website this weekend? Start here...

Install WordPress on Your New Web Site in 5 minutes

(Reading time: 7 – 12 minutes)

Welcome to the second hour of Website In A Weekend. You have a hosting account, and now we’re going to install WordPress really fast. It only takes about 5 minutes! But you do need to take some notes, so have a cheat sheet ready for marking down user names, passwords and the like.

This article was originally published on February 17, 2009. It’s been revised, corrected and republished. If you find any errors, please leave a comment. Errors will be instantly annihilated.

Install WordPress

Installing WordPress can be quite easy, a matter of minutes.

There are two common ways:

  1. Install using a hosted script such as Fantastico, or Simple Script if on Bluehost. If you use an automatic script such as Fantastico or Simple Script, be vigilant about keeping your site upgraded because these scripts control your upgrade data instead of WordPress.

    Also, you may run into issues with paths, which will affect how files and images are stored. Read more about this in the article “Fix For Not Being Able To Upload Images Properly In WordPress” by Josh Kohlbach

  2. “Manual” install creating databases and passwords. Installing manually takes a little longer, but you will learn a few basic website operation skills that will pay you back later.

I recommend using the manual instead of scripted install, but I’ll provide instructions for both, starting with manual install.

Hey! You're in the middle of the Website In A Weekend eCourse. Learn how to create and operate a complete WordPress-based website in a single weekend. Start here: Website In A Weekend: Friday Evening - Off to the Races. (If you already have a blog... "audit" the eCourse... you'll find plenty to do.)

Manual install

  1. Log in to bluehost.com cPanel for your account. For this tutorial, we’re going to refer to your account name using the fictitious “sitename.”
  2. Scroll down to the “Databases” box, and click on the first (leftmost) icon captioned “MySQL® Databases.”
    MySQL image link in cPanel

    MySQL image link in cPanel

  3. Create a database with a name using letters and numbers. For example, “word1″ which will result in a database named “sitename_word1.” Bluehost always prepends your login name to the database name to ensure your database has a unique name.*
    Create MySQL Database cPanel interface

    Create MySQL Database cPanel interface

  4. Create a database username using letters and numbers, for example: “usr1,” which results in “sitename_usr1.” Make sure that the password is easy to remember, but has a lot of mixed letters, numbers and characters in it.
    Create MySQL database user in cPanel interface

    Create MySQL database user in cPanel interface

  5. Write down your database username, database name and password on a piece of paper. You’ll need these again soon, then you can tear the paper up and throw it away.
  6. Scroll down to “Add User to Database,” and use the drop down menus to add “sitename_usr1″ to “sitename_word1″ database, giving the user ALL rights on the next screen (Check the top middle box).

    Add MySQL database user to database in cPanel

    Add MySQL database user to database in cPanel

  7. Return to cPanel and log out, you’re now done with database creation. You did write down your database, username and password, right?
  8. Download the latest version of WordPress and unzip the wordpress.zip file. You can stash the unzipped WordPress directory on your desktop for convenience.
  9. Configure WordPress to use the database. There’s two ways to do this: A. the easy way, and B. the not-quite-as-easy way. Let’s look at the easy way first.
    1. A. Let WordPress modify the configuration file.
      Hat tip Hat tip : Hat tip: Jennifer Jinright at Gurl’s Asylum provided the following extremely helpful technique which makes manual install even easier.

      This is really easy. Once you have your database installed and the names of the database and database user and password, simply navigate your browser to the URL where you installed your blog, press the buttons and fill in the blanks as necessary. It’s really self-explanatory!

      Letting WordPress modify the configuration when installing.

      Letting WordPress modify the configuration when installing.

      Necessary items for allowing WordPress to configure it's own installation.

      Necessary items for allowing WordPress to configure it's own installation.

      The next screen is where you actually enter all the information. These screenshots came from live installations… not going to broadcast usernames and passwords showing my next screen!

    2. Manually modify the configuration file. Browse the unzipped WordPress directory (probably named “wordpress“) to find the wp-config-sample.php file. You need to make a few changes in this file.

      Edit wp-config-sample.php in a text editor (like WordPad) and change the database name, the database username and the password to match the names and password you created in cPanel (and which you wrote down on that piece of paper). Typically, you will see lines like:

      17
      18
      19
      20
      21
      22
      23
      24
      25
      
      // ** MySQL settings - You can get this info from your web host ** //
      /** The name of the database for WordPress */
      define('DB_NAME', 'mydatabasename');
       
      /** MySQL database username */
      define('DB_USER', 'myusername');
       
      /** MySQL database password */
      define('DB_PASSWORD', 'mypassword');

      Where it says “mydatabasename” you’ll write (say) “sitename_wrd1“… or whatever you have written on your handy paper. Do the same for DB_USER and DB_PASSWORD.

      For now, skip all the authentication variables (AUTH_KEY, SECURE_AUTH_KEY, etc.). Starting on or near line 50 is where you can change the database table prefix from it’s default value of “wp_” to whatever you like.

      50
      51
      52
      53
      54
      55
      56
      
      /**
       * WordPress Database Table prefix.
       *
       * You can have multiple installations in one database if you give each a unique
       * prefix. Only numbers, letters, and underscores please!
       */
      $table_prefix  = 'wp_';

      Renaming the “wp_” table prefix to something else slows down hackers and increase security. Save this file as “wp-config.php.”

  10. FTP all your WordPress files to your server’s public_html directory. If you are using an “addon domain,” say “mycooljunk.com,” this will be the public_html/mycooljunk directory.
  11. Now give the URL to your website in a browser, and follow the very simple instructions to setup WordPress and login. Once you are logged in, you are free to change your password for the WordPress website to something easier to remember. Or leave it as is, because WordPress gives you a very secure default password.

Believe it or not, I can do all of the above in less than 5 minutes! It’s not difficult, but there are a few moving parts, so you should be able to get it done in an hour or so.

Scripted install

Fantastico first:

  1. Login in to cPanel at bluehost.com
  2. Click on the bright blue Fantastico icon near the bottom of the cPanel front page.
  3. Select “WordPress” from the menu of available software.
  4. Fill in the boxes on the left pane of the browser window. Use “admin” for both name and nickname for logins. Use an easily accessible email address to get started. I use my gmail.com account for convenience.
  5. Log in to your new WordPress blog using the information you gave Fantastico, and save the email you get. You may need it later.

I personally don’t use Fantastico because I like to be able to fix any (rare) security issues directly in WordPress without waiting for the Fantastico script to update.

The Simple Script system provided by Bluehost.com is even easier: here’s a screencast for Simple Script WordPress installation.

NOTE: Be careful when upgrading. Both Fantastico and Simple Script store versioning information outside of WordPress. If you upgrade WordPress internally (recommended), neither of these scripts will know, and will continue to prompt you fir upgrades. Annoying.

You can find a breakdown of both manual and scripted procedures shown graphically in my mega-giant WordPress MindMap.



*Bluehost provides you with an account login name used to get to the cPanel interface. They use this 8 letter name in a variety of ways. Here, the MySQL server processes requests for a large number of accounts, so putting your login name before your database name makes it unique, ensuring that you and only you will be able to use that database.


Practical WordPress Tip #1: Use the “View” link for URL shortcut

(Reading time: 2 – 2 minutes)

Having lots of high-quality links connecting your blog posts to each other helps you get better search engine rankings.

Problem: Digging out URLs for hyperlinks to your own posts and pages gets tedious and annoying once you have more than a few dozen articles.

Practical WordPress Tip: Use the “Edit Posts” page to copy the link address (URL) from the “View” link.

Here’s how:

  1. Using a new browser window or a separate tab, navigate to “Edit >> Posts”
  2. Search for the post you desire
  3. Right click the “View” link. Choose “Copy link address” to place the post’s permalink URL on your clipboard.
  4. Paste the link where you want it.
  5. Leave the “Edit Posts” page or tab open, repeat as necessary.

Why: This isn’t the only way to copy the URL. You could search your blog from the user side, and copy the URL out of the browser bar. But my way is much, much faster!

Here’s a screenshot with the “View” link right-clicked open:

Fast link to post URL

Fast link to post URL

Next Practical WordPress Tip:Practical WordPress Tip #2: Make Your Draft Queue Work For You“.


Do you have a Tip? Would you like to write a Practical WordPress Tip? Each Tip is very short, and focuses on a single action that anyone can use right away, no programming required! If you have a Tip that fits into this series, and you’d like to publish it here on Website In A Weekend, send it on!