Last month I bought my first Arduino (actually a SparkFun RedBoard) and started playing around with Johnny-Five to control it via JavaScript. Since then, I’ve learned the basics of electronics, microcontrollers, and how Johnny-Five works. This weekend, I decided to buy a cheap RC car and see if I could hack the remote so I… Continue reading Controlling an Off-the-Shelf RC Car with an Arduino
Blissful Testing of Locally Hosted Sites
When I first started using a web server on my local machine for development, I used to create a separate virtual host for every site I worked on. Then I learned that you can use a ServerAlias with a wildcard to handle multiple sites with a single virtual host. Since then, I’ve been using the… Continue reading Blissful Testing of Locally Hosted Sites
Creating Application-specific jQuery plugins
When building an application with jQuery, it’s very likely that you will end up writing some code that would be easiest to use directly in a jQuery chain. When the functions you’re writing solve general problems that don’t have a dependency on your application, it’s usually obvious that you should write the function as a… Continue reading Creating Application-specific jQuery plugins
Long polling in Node.js
Note: Node is currently under heavy development and the API is in a state of flux. This article was written to be compatible with v0.1.95, the most recent version of Node at the time. The examples in this article may not work with future versions. Many web developers seem to think there is some sort… Continue reading Long polling in Node.js
Building stateful jQuery plugins
Background Over the past few years, jQuery has dominated the web development community with its simple, yet brilliant, API. The “find elements, do something†pattern and ability to chain function calls together combine to create code that reads like English. jQuery’s simplicity and almost nonexistent learning curve have made it extremely popular among developers and… Continue reading Building stateful jQuery plugins
Using multiple versions of jQuery
Whenever a new version of jQuery comes out, there are several reasons to upgrade; new features, bug fixes and performance are generally the most common. However, it’s not always possible to upgrade as soon as a new version comes out. The new version may contain an API change that would break some of your functionality… Continue reading Using multiple versions of jQuery
Creating dialogs on demand
In a previous article, I explained how to load a page into a dialog. The article focused on a simple solution to keep it easy to understand. However, that simplicity does come with a drawback; the page contents are loaded immediately after the document is ready, even if the user never opens the dialog. In… Continue reading Creating dialogs on demand
Loading a page into a dialog
I previously showed the basic usage of the jQuery UI dialog. In this article, I’ll show how to open a page in a dialog. We’ve all been to sites where there’s a help link that opens a popup with some short help text. This is usually done with a simple window.open call attached to the… Continue reading Loading a page into a dialog
Basic usage of the jQuery UI dialog
The jQuery UI dialog, like many jQuery UI plugins, is extremely easy to get started with but has a few areas that causes new users some trouble. One of the most commonly asked questions on the jquery-ui list is “Why does my dialog only open once?” In this article I’ll explain the problem these users… Continue reading Basic usage of the jQuery UI dialog