WordPress HTML Cheat-sheet

I’m putting this little post together to help my clients on WordPress, and hopefully a few other folks out there when composing WordPress posts and pages.  Please comment below with questions/additions, as I’ll continue updating this post.

Audience:
This cheat-sheet is intended for users using the WordPress CMS, and would like to have a bit more control over the layout and formatting.  It is not a complete guide to HTML, rather is focused on HTML formatting for using the WordPress post and page functions.

Scope:
We will be reviewing how to better format content within the Visual and HTML tabs for WordPress pages and posts, relying on WP’s built in rich text editor, a few HTML snippets, and a basic synopsis of CSS styles as they are relevant. Things such as Doctype and <head> tags that are not editable from the editor will not be covered.

Continue reading

Internet Explorer 6's last nail in the coffin: Google

What’s the #1 reason I enjoy doing back end programming instead of front end design? No, it’s not my lackluster aptitude at graphic design - it’s internet explorer version 6.

See, IE6 thinks it’s better than everybody else, and I’m thankful to the lord that even Big G is now backing up.  It ignores internet wide standards like xhtml and css, and follows it’s own rules. Yesterday, Google announced that it is ending it’s support for IE 6!  The version 6 basher’s list is long and somewhat illustrious, even including it’s developer – Microsoft.

In short, I’ll save you guys the techno explanation of why IE6 is bain of all web designers’ existence – and just say that over 20% of front-end development time goes into bug fixing and hacking custom scripts and styles for a program that was released before those bastards took out the twin towers.

At some point, we’re going to have to enact a surcharge for IE 6 compliance – and I wonder how many other firms are already doing this or forgetting IE 6 entirely?

States HTML Select List w/ PHP Selected Value

I always have trouble finding this, so here it is. The if statement in the checkState() function can be replaced with anything you like to select the option by default…

<?
function checkState($state) {
  if ($row['state'] == $state) {
    echo ' selected="selected"';
  }
}
?>

<select name="state" id="state">
 <option value="--"<? checkState('') ?>>Select...</option>
 <option value="AL"<? checkState('AL'); ?>>Alabama</option>
 <option value="AK"<? checkState('AK'); ?>>Alaska</option>
 <option value="AZ"<? checkState('AZ'); ?>>Arizona</option>
 <option value="AR"<? checkState('AR'); ?>>Arkansas</option>
 <option value="CA"<? checkState('CA'); ?>>California</option>
 <option value="CO"<? checkState('CO'); ?>>Colorado</option>
 <option value="CT"<? checkState('CT'); ?>>Connecticut</option>
 <option value="DE"<? checkState('DE'); ?>>Delaware</option>
 <option value="DC"<? checkState('DC'); ?>>District Of Columbia</option>
 <option value="FL"<? checkState('FL'); ?>>Florida</option>
 <option value="GA"<? checkState('GA'); ?>>Georgia</option>
 <option value="HI"<? checkState('HI'); ?>>Hawaii</option>
 <option value="ID"<? checkState('ID'); ?>>Idaho</option>
 <option value="IL"<? checkState('IL'); ?>>Illinois</option>
 <option value="IN"<? checkState('IN'); ?>>Indiana</option>
 <option value="IA"<? checkState('IA'); ?>>Iowa</option>
 <option value="KS"<? checkState('KS'); ?>>Kansas</option>
 <option value="KY"<? checkState('KY'); ?>>Kentucky</option>
 <option value="LA"<? checkState('LA'); ?>>Louisiana</option>
 <option value="ME"<? checkState('ME'); ?>>Maine</option>
 <option value="MD"<? checkState('MD'); ?>>Maryland</option>
 <option value="MA"<? checkState('MA'); ?>>Massachusetts</option>
 <option value="MI"<? checkState('MI'); ?>>Michigan</option>
 <option value="MN"<? checkState('MN'); ?>>Minnesota</option>
 <option value="MS"<? checkState('MS'); ?>>Mississippi</option>
 <option value="MO"<? checkState('MO'); ?>>Missouri</option>
 <option value="MT"<? checkState('MT'); ?>>Montana</option>
 <option value="NE"<? checkState('NE'); ?>>Nebraska</option>
 <option value="NV"<? checkState('NV'); ?>>Nevada</option>
 <option value="NH"<? checkState('NH'); ?>>New Hampshire</option>
 <option value="NJ"<? checkState('NJ'); ?>>New Jersey</option>
 <option value="NM"<? checkState('NM'); ?>>New Mexico</option>
 <option value="NY"<? checkState('NY'); ?>>New York</option>
 <option value="NC"<? checkState('NC'); ?>>North Carolina</option>
 <option value="ND"<? checkState('ND'); ?>>North Dakota</option>
 <option value="OH"<? checkState('OH'); ?>>Ohio</option>
 <option value="OK"<? checkState('OK'); ?>>Oklahoma</option>
 <option value="OR"<? checkState('OR'); ?>>Oregon</option>
 <option value="PA"<? checkState('PA'); ?>>Pennsylvania</option>
 <option value="RI"<? checkState('RI'); ?>>Rhode Island</option>
 <option value="SC"<? checkState('SC'); ?>>South Carolina</option>
 <option value="SD"<? checkState('SD'); ?>>South Dakota</option>
 <option value="TN"<? checkState('TN'); ?>>Tennessee</option>
 <option value="TX"<? checkState('TX'); ?>>Texas</option>
 <option value="UT"<? checkState('UT'); ?>>Utah</option>
 <option value="VT"<? checkState('VT'); ?>>Vermont</option>
 <option value="VA"<? checkState('VA'); ?>>Virginia</option>
 <option value="WA"<? checkState('WA'); ?>>Washington</option>
 <option value="WV"<? checkState('WV'); ?>>West Virginia</option>
 <option value="WI"<? checkState('WI'); ?>>Wisconsin</option>
 <option value="WY"<? checkState('WY'); ?>>Wyoming</option>
</select>