Regular Expression for Pattern Attribute in Form Field

MySQL databases accept dates in many different formats. For example, YY-MM-DD, YYYY:MM:DD, YYYYMMDD, and YYYY-MM-DD, among the myriad options for date formatting. (Y is for year, M is for month, and D is for day.) Embracing HTML5’s pattern form attribute, which accepts a regular expression pattern, I wanted to accept dates from 0000-00-00 through 2015-12-31. […]

Each of the US States Listed Inside Option Tags for HTML Forms

If you’re working with all the US states and you need to list all of them in a form, download the following Gist from GitHub: It’s a self-submitting form (in PHP) and defaults to the GET method for posting.

Definitions: User Agent, User, and Author

It’s important to understand the distinction between the terms “user agent,” “user,” and “author” when discussing CSS’s cascade. A user agent, or UA, refers to any browser when the term is used to discuss web-based technologies. Firefox, Chrome, and Opera are all user agents. A user is synonymous with a computer user. For example, I […]