Archive image

Archive for July, 2012

Simple form validation in PHP

Server-side validation of user input is something you run into once in a while and although it is not an overly complicated subject, there are a couple of gotchas to be aware of.

This blog post examines how to validate a simple form in PHP.
First we need a form. It could look something like this:

Read more…

Inspect object in PHP

To display the contents of an object in ruby is really simple.
All you do is store the object in a variable, then pass the variable as an argument to the Kernel method p(), which in turn writes obj.inspect to the standard output.

Read more…

Making a Very Simple WordPress Theme for a Static Site

Despite starting life as a blogging platform, WordPress can also be used as a fully functional CMS. The following steps describe how to skin WordPress for use as a CMS with a simple “brochure” style website.

Read more…

Using Regular Expressions in Dreamweaver

Recently, I had to change the following HTML:

<h3>Short academic profile:</h3>
  2000 - 2005: Studies in something at a university somewhere<br />
  2005 - 2010: Different studies at a different uni<br />
  Since 2011: Very important studies somewhere else<br />

Read more…