Chickenfoot 0.9.20070423 released

This release includes some new debugging features:

  • When a pattern is ambiguous (like click(”Search”) on a page with two Search buttons), Chickenfoot now highlights all the matches to the ambiguous pattern.
  • Objects displayed in the output pane can now be opened to show their properties.

In addition, Chickenfoot scripts can now use Javascript 1.7 constructs, assuming you’re running in Firefox 2.0+. (FF 1.5 only has JS 1.6.) In particular, Match objects are now iterators, so you can do away with the nasty hasMatch/next syntax and simply use, like so:

for (c in find(”checkbox”)) check(c);
for (img in find(”image”)) remove(img);
for (number in find(/\d+/)) output(number);

JS 1.7 has a few other nice features, like proper lexical scoping for local variables. See
for more details.

The file-handling commands (read, write, append, exists) have been moved out of the Chickenfoot core and into a library. You need to put include(”fileio.js”) at the top of your script to use these commands.

Also fixed a bug in the extension generator, so that Firefox extensions generated from Chickenfoot work once more.

Chickenfoot 0.9.20070227 released

Minor bug fix that allows trigger scripts to run when the Chickenfoot sidebar is closed.

Chickenfoot 0.9.20070226 released

For the first release of 2007, we have the following treats:

- Triggers can now fire whenever Firefox starts, or whenever a new Firefox window opens. This will be useful for changing Firefox’s chrome, e.g. adding toolbars or menu items from Chickenfoot scripts.
- Chickenfoot scripts can now be triggered from the Firefox command line. Use firefox -cf-run to load and run a Chickenfoot script right after Firefox starts.

- pick() and enter() now simulate onchange events when they change a checkbox, radio button, listbox, or textbox, so Chickenfoot will play better with Javascript-intensive web sites.

- there is now a Stop button on the Chickenfoot sidebar, right next to the Run button. It makes a best effort to stop any running Chickenfoot scripts, although it may not succeed if a script is CPU-bound (because that usually locks up the user interface too).

- fixed a few bugs, such as click(”Next”) not working on Google search results

Chickenfoot 0.9.20061127 released

Chickenfoot now has a new feature called keyword commands, which allows simple scripts to be written without knowing any Javascript syntax. For example, here’s a simple script of commands that takes you to the Chickenfoot page:
go to
type “chickenfoot mit”

Keyword commands are still an experimental feature, not enabled by default. You can switch to keyword command execution mode by using the new drop-down menu on the Run button. Keyword commands require Java support in your browser.

The Chickenfoot script editor also now supports Ctrl-Enter to execute the current line in the editor. Ctrl-Enter provides the same behavior as a command line (such as the Javascript command line in the Error Console). Ctrl-Enter works on both Javascript code and keyword command code.
Bug fixes:

  • Java is now loaded lazily when needed, rather than every time Firefox starts.
  • Packaged Chickenfoot extensions can now be installed in Firefox 2.0.
  • The fetch() command no longer conflicts with AdBlocker or causes crashes on MacOS when no Firefox windows are visible. Instead, fetch() now loads pages into invisible tabs in the current window.
  • Triggers now run on the first page loaded by Firefox.
  • A number of startup race conditions have been fixed. Symptoms of these bugs varied, but generally Firefox refused to start up, hung on startup, or started up with important features disabled, like the Back/Forward buttons or menu items. Because it was a race condition, these effects were intermittent, not seen all the time or on all platforms.

Chickenfoot 0.9.20060922 released

Fixes “Components.classes[cid] not found” bug sometimes seen on Windows.

Chickenfoot 0.9.20060916 released

Chickenfoot now uses a new native library to wait for pages to load, which Chickenfoot scripts can now run on Mac and Linux without having to use whenLoaded(). Hooray!

In other news, Chickenfoot now runs on Firefox and Firefox 2 Beta 2.

Other changes:

  • Fixed bugs in XPI export mechanism. If you exported a Chickenfoot script as an XPI, you’d be advised to do it again.
  • Fixed bug on Mac OS that caused the main Firefox window to have garbage appearing in it.

Chickenfoot Tech Talk on Google Video

Last week, Rob and I gave a tech talk at Google about developing JavaScript in Chickenfoot, but we also talked about keyword commands and showed off a number of demos.
The talk is available on Google Video, and
if you expand the Details link on our Google Video page, it brings you to important points in the talk.

Now we also have a dedicated publications page for Chickenfoot so you no longer have to dig through the FAQ to find the papers we’ve written. The new page also has a high-resolution copy of the tech talk in case you want a better look at the demos, but put if you decide to watch it, put some coffee on because it’s a whopping 437MB, so it may take a little while to download.

Chickenfoot 0.9.20060727 released

Fixed some bugs related to packaging Chickenfoot scripts as standalone extensions. Exported Chickenfoot scripts were trying to find the chickenfoot/setup directory in the end-user’s Firefox profile directory. If the end-user had never installed Chickenfoot, this directory would not exist, causing the extension to crash. Also, ==UserScript== tags were not being written back into a script correctly by the packaging tool if the tags did not already exist in the script. Both of these issues are now fixed.

Updated installation page to explain what happened to the TC constructor. The use of TC patterns is no longer supported in Chickenfoot. Using them now requires an additional extension that works in conjunction with Chickenfoot. We are trying to phase out TC patterns in favor of equivalent keyword patterns that will run faster and will not depend on Java.

Can run a trigger by right-clicking on a page and selecting it. Utility scripts, such as Dump current HTML, are not appropriate to install as triggers because they should not run every time a page loads, just when the user needs them (hence the term “utility”). To that end, we have added a context menu that lets you right-click on a page and run any script listed in your Triggers pane. This list includes triggers that aren’t checked in the pane, which makes this feature well-suited to utility scripts.

Chickenfoot 0.9.20060721 released

Chickenfoot scripts can be packaged as standalone Firefox extensions. With the click of a button, you can turn your script into an extension that others can install and use. This feature makes it simple to create a web prototype and share it with friends and colleagues.

New libraries bundled with Chickenfoot: Scriptaculous and Prototype. Prototype is “a JavaScript framework that aims to ease development of dynamic web applications,” and is a powerful AJAX library that builds on top of it.

Users can define their own script templates. Suppose you want to use Prototype whenever you open a Chickenfoot edit buffer. Now you can create a template with the code include("prototype.js") and set it as your default template so every new buffer contains that code.

Basic table/row/cell patterns are supported. It is possible to locate tables, rows, and cells with the find() command: find("3rd table").find("2nd row").find("5th cell"). So far, we only support ordinals for identifying these elements — we plan to support table/row/cell as keyword patterns in the near future.

New “run selected text” feature lets you run part of a script. You can select any part of your script, right-click, and choose “Run selected” in order to execute it. This is handy if you only want to test a portion of your script.

Recognize “id” keyword pattern. As an alternative to document.getElementById("tableOfContents"), you can use find("tableOfContents id").element instead. Like other Chickenfoot commands, find() traverses subframes when looking for a match, so it can be more convenient than getElementById on sites with many frames, such as Gmail.

Stack traces are printed in the Output pane. When an error is thrown, its stack trace is printed along with the error message to help with debugging.

The core of Chickenfoot no longer requires Java. Previously, users needed the Java plugin for Firefox in order to run Chickenfoot. Now users only need Java if they want to use the extension creation tool or to take advantage of the ability to synchronize scripts with page loads on Microsoft Windows.

Chickenfoot 0.9.20060607 released

A new version of Chickenfoot is out, with several major improvements and bug fixes.

Every Chickenfoot script and trigger now runs in a fresh, private namespace. Formerly, all Chickenfoot scripts shared the same namespace, so it was easy to share global variables between scripts, but scripts could step on each other inadvertently. Most scripts won’t notice this change at all. But if you use global variables to pass information between two scripts, or to store information between subsequent runs of the same script, you’ll have to change your script’s behavior. A new Chickenfoot object, global, provides a place for keeping these global variables. Just prefix the global variables you want to share with global, e.g. global.myVariable, and every script will be able to see them.

The script editor now has multiple tabs, so you can edit multiple scripts at the same time, and use scratch editors for testing and experimentation. The script editor also now has keyboard shortcuts for its toolbar buttons: Ctrl-N for new file, Ctrl-O to open a file, Ctrl-S for save, Ctrl-W for close file. These shortcuts override Firefox’s meaning for these keys only if the focus is in the script editor.

Regular expression support. find() can take a regular expression, which it searches for in the text of the page, e.g. find(/ISBN: \d+/). Parenthesized groups in the regular expression are placed on the Match object as an array called groups.

Image searching. find() can now search for images, e.g. find(”Google image”). Keywords are taken from the image’s ALT text and from text around it in the page.

Other changes:

  • Chickenfoot triggers can now be disabled using a Firefox preference, so that you can deal with a misbehaving trigger that cripples Firefox. The Chickenfoot FAQ explains how.
  • Pattern matching now uses context properly, so you can say find(”search form”).click(”button”).
  • Patterns now look for keywords in ALT attributes of image buttons.