Articles tagged with ‘javascript’

Disable HTML5 form validation with novalidate

One of the most useful things the HTML5 doctype provides developers is the ability to validate form inputs ‘inline’—validation performed by a user’s browser, with no reliance on JavaScript and to the W3C standard. This article isn’t about how to wield the new types: plenty of people have done an excellent job of that already. Instead, we’re going to take a brief look at how to disable this validation on an ad-hoc basis when we want to test our server side validation logic.

Full article (759 words)

Bootbox 2.0.0

The arrival of Twitter's second major version of Bootstrap heralds a new release of Bootbox, a simple JavaScript library I wrote back in November last year to programatically leverage Bootstrap's modal functionality. Shadowing Twitter's release like this is somewhat inevitable—their 2.0 branch is not compatible with older 1.x releases, so by upgrading Bootbox's dependency it too automatically becomes incompatible with older versions.

The upgrade process from 1.1.2→2.0.0 is pretty straightforward: this article explains the major changes, discusses some new dependencies and introduces some minor additional functionality.

Full article (459 words)

Combining AJAX, pushState and CSS3 transitions

I've never been entirely satisfied with the colour scheme used on this site—when rebuilding it I could never decide on a theme I was happy with but in the end settled on the deep-purplish colour you'll now only see on the home page. I've often mused about having a different theme per section but never found a good enough reason to do it until recently, when I decided to learn a little more about CSS3 transitions and HTML5 pushState, with a specific idea in mind of how I wanted to apply them to the site.

Full article (2,570 words)

Nodeflakes - real time tweet powered snowflakes

The snowflakes you can hopefully see gently floating down your screen are real-time representations of tweets, taken live from Twitter's Streaming API. The size of each flake is loosely based on the author's follower count, and hovering over each flake will reveal the tweet it represents complete with highlighted hashtags, usernames and URLs.

Full article (1,956 words)

Bootbox.js - alert, confirm and flexible dialogs for twitter's bootstrap framework

I’ve been using twitter's bootstrap framework for a number of site builds recently, mainly because it gets me from black-and-white markup to vaguely-presentable websites in a very small amount of time. Version 1.3 introduced some JavaScript plugins to complement the array of stylistic elements it already provided - notably code to invoke dialog boxes, or modals.

Full article (1,610 words)