Skip to main content


Alternating Background Images

Today I want to show you how in just a few lines of jQuery code we can alternate or swap out the background image for any ID or CLASS.

The task of changing the CSS properties and setting a new background image is much simpler than you might expect and you may even find my method is quite a bit easier than other examples you've found. So, let's get into it shall we?

In the HEAD portion of your HTML document you'll need to include a link to the latest jQuery file. As you'll see from my example below, I'm linking to the jQuery site itself, but you could of course use Google's hosted jQuery library or even download a copy to your system and place it in a sub-folder to the site.

<script type="text/javascript" src=""></script>

The upside to linking to a hosted library is speed and accessibility. While you may think that having a copy of the jQuery library  on the website itself would be faster …
Recent posts

HTML Form Preparation

Today I want to discuss preparing the data a user would enter into one or more HTML forms you might have on your website prior to sending it off to a script for processing.

While many of these tasks could be performed on the server side within the processing script, I think it's important to get into the habit of sending the data in it's proper form & format that the script will expecting it in, especially if that data will be saved to a database.

To begin, let's take a look at a very common HTML Sign Up form...

<form action="./scripts/register.php" method="post" enctype="multipart/form-data" id="registeruser" name="registeruser">
            <fieldset class="fifty">
                <input name="First" type="text" size="10" maxlength="25" autofocus id="First" placeholder="First Name" />

HTML/PHP Advanced Guestbook

The single most popular post from my blog is by far the Guestbook using HTML/PHP, which for me personally seems a little odd, but apparently it's what you wanted to know about. And far be it for me to argue with what you want to learn about.

 So, with that in mind, I thought I'd revisit that topic and lend a hand at creating a much more advanced Guestbook or Online Chatting System.

 If you read the previous post, then you already know that the basic setup is to create an HTML form to allow your users to enter in their name and some comment, then we store that information into a text file called GuestBook.dat, and finally, read in that file and display it to the users.

 The original post and information there gave an example of a very basic guestbook, and was to be honest, a bit clunky.

 To get started, first create a PHP document, and then at the very top of that document add the following code:

    if (!isset($_SESSION)) { session_start(); }
    // Advanced Guestbook…

Project Planning & Web Design

Proper project planning is a must-do for any project, while failure to consider all aspects of a given project before implementation can mean certain doom.

 As an Implementation Engineer, I am very much a part of the planning phase for every project I am involved with. And as such am accustomed to planning every step as well as establishing success & failure factors. In my Website Designing business, I carry over those same principles with me because they are no less important there.


 Proper planning means to consider every aspect of a given project, including the client's needs, workflow, and customer base. In general you'll need to consider what the end result should look like, feel like, and what the success factors will be. Another words, what are you trying to accomplish and how do you calculate success or failure.

 When it comes to designing websites you may be inclined to just jump right in and start designing something based on your first client meeting o…

Form Validation Using jQuery

How many times have you sat down and designed a login form of some sort for a client only to get frustrated with it because you couldn't figure out a way to validate the information the user entered before sending it off to your script for processing?

 Well, that's about to change, because what we're going to cover today is exactly that. An easy way to validate any form input using some simple markup and jQuery.

 But before we get into the solution, let's take a look at a standard form and the typical flow of processing that data. First we have the HTML form itself:

<form action="register.php" method="post" enctype="multipart/form-data" name="register" id="register" >
      <input name="First" type="text" size="10" maxlength="25" autofocus id="First" placeholder="First Name" /><br /><br />
      <input name="Last" type="t…

Flat Design - Passing Fad or New Staple

As you no doubt have heard, many designers have or are turning to flat design. And there appear to be several reasons for this many of which reflect solely on that designer's personal preference, but if you think the reasons stop there, read on.

 Flat design is a style that lacks the “tricks” designers often use in order to create a realistic or three-dimensional effect. The style is characterized by an overall minimalistic look, bright but muted colors, bold - often retro typography and simple user interface elements such as buttons or icons.
Flat design techniques avoid embellishments such as bevels, embossing, drop shadows, gradients or artificial textures. Typically you will see flat designs used in mobile applications or in web sites with only a few pages, and rarely if ever will you find any sort of animation in a flat design.

 So this begs the questions: Why would you use it or when should you use it? Unfortunately there's no short answer to either of those questio…

MySQL Databases & PHP Scripting- Part V

I know it's been a couple of months since the last post, but it's time to round out this 5-part series with information on how to create and check browser-side cookies plus generating HTML encoded e-mails.

 To get us rolling let's do a quick review about the previously discussed method for tracking a user's session. In Part II of this series:, I outlined how to create a session variable when a user logs in, and then how to check to see if a user is already logged in by checking if our session variable is set (as shown below).

   if isset($_SESSION['USER'])
      // User is logged in. Show the rest of the page or information as applicable
        // User is not logged in. Take them back to the homepage.
        header("Location: ../index.php?action=no");

 What we'll focus on today is a slightly different …

MySQL Databases & PHP Scripting- Part IV

Are we having fun with PHP yet? I hope the answer is yes, and it only gets better from here. Previously we've covered quite a bit of ground going over how to create our initial database structure, complete with a few tables to get us going, plus the scripts to add to those tables as well as pull data from them.
 Today we're going to get into how to update those same tables and how to write to a log file so we can track what's going on within the web site.
 So as we've learned previously, when inserting data into a table we need to use the INSERT INTO command along with the table we want to toss the data into, plus of course the column names and the data itself.  When we want to pull the data back out, which is to say read from a table, we use the SELECT command and choose the what columns to read plus the name of the table.
 So following this same line of thinking, when we want to update a column in a table, we can use the UPDATE command, which would look something …

Is Your Web Design Website Up to Par?

Unfortunately all too often I run across web designer websites that lack... well, finesse & professionalism. They are either trying to deliver too much content to the user, have words that are misspelled, use poorly designed graphics, the site doesn't render correctly for tablet or mobile phone users, makes use of horrible color combinations, or simply has a very unstructured, hard to navigate menu system.

  And let's face it, we're supposed to be the pros. So if you're a web designer, your website better rank in the great or spectacular category. Otherwise I suspect you will have a lack of clients flowing through which means less revenue for you and your colleagues.

 There are a few simple rules to follow when designing any website, and these include but are not limited to:
ScalabilitySearch Engine OptimizationAestheticsFriendly Navigation  Let's go over each one individually so we're all on the same page and understand the tasks at hand.
 Scalability is …

MySQL Databases & PHP Scripting- Part III

Welcome back to the third part of this 5-part series, MySQL Databases & PHP Scripting. In the last two posts we covered how to create your first database using phpMyAdmin and within that new database, how to create a basic table structure to store some information like a Username & Password. We covered the basics behind securing the database using a registration form & script as well as a login form & script. And we touched on session variables and how we can use them to temporarily store information that we need while a user is logged in to the site.
 Storing information to a database is a relatively easy thing to do as we learned in our last post located at: Today we're going to get a little more detailed in the storing & retrieval process, plus we'll touch on how to make storing passwords a little more secure.

 If you followed our last two posts in this series, …