Major new release of Marginalia for Moodle

I have uploaded a major new December 2008 version of Marginalia for Moodle. You can download it at the Google Code site. This release is Beta: it is feature-complete but has not been fully tested. If you run into problems installing the software1 or if it behaves erratically, please – let me know! My email address is displayed on my home page.

Among the changes in this release:

  • a significant fix for a bug that could cause highlights to be confused or margin notes to be displayed in the wrong places
  • support for Safari and Internet Explorer 7
  • a new feature to make it easy to quote from posts and annotations when writing new forum posts in Moodle
  • autocompletion for margin notes (replacing the previous “tags” feature)
  • an enhanced summary page with a simplified user interface
  • better Moodle integration with a simpler install procedure

For more detail on the changes, see the release notes for December 2008.


1 I notice the release I silently uploaded last night has already been downloaded twice. I’m afraid the installation was broken – sorry! If you find the install process doesn’t work as it’s supposed to, please contact me. Install issues can fall through the cracks. They are often quite simple for me to remedy, saving trouble for you and for anyone else who downloads the software.


Marginalia wins innovation award

Marginalia has won the BC Innovation Award in Educational Technology! Thank you to everyone who has supported and used the software. We plan to introduce a number of improvements over the next little while, and we hope this award will introduce the software to new users and uses.


Marginalia Release

While I haven’t posted about Marginalia in a long time, I have been making significant enhancements. These were prompted mainly by work on integration with and features for the Bungeni system for parliamentary information systems. Downloads for Moodle and Open Journal Systems are available on the Code site, along with full current source code in the repository (follow the link from the Download page).

Among the new features:

  • some very important bug fixes
  • a multi-user interface for displaying public annotations by multiple users at once on a per-paragraph basis (in OJS, Bungeni, and the demo)
  • users can edit personal lists of keywords (this version of keywords is only currently used by Moodle; OJS still uses a static keyword list)
  • Marginalia can be used as a kind of track changes feature, in which highlights indicate insert, edit, and delete actions (used in Bungeni)

The Moodle version adds further enhancements:

  • keywords, as in OJS, which each user can customize (called “tags”)
  • a search and replace feature for margin notes
  • the summary page can display all annotations for a given forum (in addition to the existing per discussion and per course display)
  • online help
  • splash text to introduce users to Marginalia

The following improvements are relevant to developers:

  • the Bungeni portal project is maintaining a Plone implementation of the Marginalia service
  • a modified database format to allow Marginalia to determine overlapping highlight regions without looking at the annotated document
  • most of the PHP code necessary for a Marginalia server implementation is provided in a library
  • applications can override Marginalia’s default margin note display and editor functions (Bungeni does this extensively)
  • there’s a mechanism for preventing cross-site request forgery of annotation actions (keywords and preferences are not yet protected, however)
  • Marginalia is easier to configure, so that different applications can easily determine which features to support (e.g. track changes in Bungeni, per-user keywords in Moodle)
  • integrating Marginalia with host applications is more straightforward, and it’s easier to upgrade to new versions of Marginalia without touching the rest of your application code
  • improved regression tests for highlighting (the code had been out of date for some time)
  • the Atom format for annotations is easier to read and more informative as a syndication feed

Marginalia Plug-In for Open Journal Systems

I have uploaded the promised Marginalia annotation plug-in for Open Journal Systems. I recommend this for OJS users interested in experimenting with Marginalia. Because OJS is easy to install and has such a clean plug-in architecture, I also recommend this for anyone developing with Marginalia who would like to see a clean integration with another system. My previous post on this topic discusses the new features. This version does not support IE.


Marginalia stand-alone release with new features

I have released a new stand-alone version of Marginalia, my web annotation system. This includes many of the improvements made for the Open Journal Systems annotation plug-in (which I have not yet released publically). Among the improvements:

  • Marginalia is much, much faster when dealing with long documents, making it a feasible technology even for documents running to scores of pages or longer.
  • Readers can associate hyperlinks with annotations. These links appear as icons within the annotated text.
  • Margin notes can be chosen from a predetermined list as an alternative to entering them as freeform text (a button toggles between the input modes, and Marginalia remembers the previous choice of mode).
  • Numerous improvements to the source code.

Unfortunately, the new version has broken support for Internet Explorer, and I haven’t yet fixed that. For now, this is Firefox-only.

These features were made for the OJS plug-in, and were made possible by Dr. Rick Kopak’s “Navigating Information Spaces” project at the University of British Columbia, funded by the Social Sciences and Humanities Research Council of Canada. Chia-ning Chiang and John Willinsky have also been essential in getting the OJS port project off the ground.


Upcoming OJS release of Marginalia

Although I haven’t updated Marginalia recently, I have been working part-time on integrating it with Open Journal Systms. There are a number of improvements and new features in the OJS version:

  • Counting word offsets from the start of a document is very slow for long documents. The new version avoids this counting words from the start of the nearest preceding block of text (paragraph, list item, etc.) The old version froze my browser for minutes when I tried to add an annotation to the end of a 100 page document. The new version took a few seconds to perform the same task.
  • Loading a page with many annotations can also result in browser freezes. The new version loads annotations in the background so this won’t happen.
  • Annotation text can now be entered in one of two ways: freeform, as in the current version, or by picking from a drop-down list of terms. Terms have associated definitions which show up as hover text on the margin note. An expand/collapse button switches between the two modes while editing.
  • Rather than loading all annotations at once, they can be selectively downloaded for a specific paragraph. This feature was inspired by the stunning GPL 3 draft comments page.
  • Annotations remain plain text, but each one can have an associated hyperlink. Within OJS, these links can point to specific paragraphs in other journal articles, and can be created without fiddling with URLs by simply clicking on the target paragraph.

I haven’t uploaded a new version because the code is in flux. I’ve already broken compatibility with the old database format; I don’t want to release until I think things have stabilized. I do have a working version, but it does not support Internet Explorer. Despite this, if anyone is interested in an interim version, I would be happy to make it available.

The OJS version is made possible by Dr. Rick Kopak’s “Navigating Information Spaces” project at the University of British Columbia, funded by the Social Sciences and Humanities Research Council of Canada. Chia-ning Chiang and John Willinsky have also been essential in getting this project off the ground. Thanks to them and to BC Campus, Andrew Feenberg’s ACT Lab and LIDC and SFU, and Malaspina College for making the existing version happen.


Marginalia Security Alert

I have discovered and patched a security vulnerability in Marginalia for Moodle. Attackers could potentially use this to gain unauthorized access to Moodle. Anyone using an earlier version of Marginalia for Moodle should upgrade to the latest release.

The two most recent releases of Marginalia for Moodle also include a number of bug fixes and minor enhancements. The most significant of these are recorded in the change log.


Marginalia for Moodle 1.6

I have updated Marginalia to work with the current development version of Moodle 1.6. I don’t plan to continue to support Moodle 1.5.x as I don’t want to maintain two code bases. Furthermore, I figure most folks likely to try annotation will be running the most recent version of Moodle. The 1.5 release of Marginalia for Moodle is still available.

In addition to 1.6 support, this release fixes a broken Atom URL on the summary page and adds support for the current hAtom specification (see my previous post about why this is important).



First, my web annotation implementation has a new name: Marginalia. This may drop my Google rank down somewhat for searches on “web annotation”, on the other hand it will give links to the project something to call it. “Web annotation” just wasn’t cutting it anymore.

Second, I should mention a recent sticky-note annotation tutorial at IBM developerWorks provides an easy way to make Marginalia work with generic (or nearly generic) web pages. The tutorial suggests using a bookmarklet1 to allow a user to enable annotation on any page. The bookmarklet inserts the annotation Javascript code, adding the feature2.

This is easy in the case of IBMs demo, in which sticky note-style annotations are associated with an entire Web page. In my case it’s trickier, because I have highlighting of passages of text and notes in a margin. The solution, I believe, is to leverage microformats. Any page supporting a standard microformat can indicate where annotatable content is. The Javascript can then figure out where to create its margins. I planned long ago to support a blog post microformat for precisely this reason, and adopted some experimental mark-up. Now there’s a draft for hAtom. This should be adopted in a future version of Marginalia.


1 A bookmarklet is a browser bookmark (“favorite” in Microsoft-speak) that executes a short piece of Javascript. I have bookmarklets for posting to and searching Technorati set up in my browser.

2 The trick is that this avoids triggering Javascript security restrictions. Javascript cannot use XMLHttpRequest to load files from a domain other than that from which the Javascript comes. This makes it tricky to use a common annotation store for annotating pages from multiple sites. By using a bookmarklet, the Javascript always comes from the same site (the site hosting the annotation back-end), thereby avoiding the problem.



I just discovered another annotation project very similar to mine. HyLighter is a web highlighting and annotation research prototype for use in education. First developed in 2001, with annotation added in 2004, it shares the key features of my implementation: it allows users of IE and Firefox to highlight passages of text and associate text annotations.

There are, however, a number of differences:

  • HyLighter allows users to compare what they have highlighted with what others have highlighted, using colors to indicate who has highlighted what and shades to show how many users have highlighted a passage.
  • In my system, all of a users annotations are shown in a margin, each lined up with the associated highlighted passage of text. With HyLighter, the user must click on the highlighted passage to retrieve the annotation, and the notes are not lined up.
  • HyLighter allows users to see all the annotations (by all users) associated with a passage of text. My system only shows all the annotations by a single user at one time.
  • My system allows users to make their annotations public or private. In HyLighter I believe all annotations are public.
  • My annotation system is open source; HyLighter is not. Even the demo requires registration (I haven’t tried it).
  • HyLighter is a stand-alone application. My system, in contrast, is Web-aware and is designed to be easily integrated into other web applications. I have integrated it with Moodle and provided instructions for doing the same with other applications. Most of my code is in the Javascript front end, where it is independent of the web application; the back end can be extremely small (in the static demo it’s just an XML file). HyLighter, on the other hand, has a Java back end with administration features; I suspect it also has much more of its implementation code in the back end.
  • HyLighter associates annotations with documents. Mine associates them with URLs and document fragments – mine appears to be more web-ready (I could be wrong). I also export annotations as an Atom feed.
  • I have a smartcopy feature which adds context information to quotes created with copy and paste.

Their research agenda is also different: they focus on how students highlight, both to measure student learning and to improve students’ ability to select key passages of text. They also suggest using HyLighter as an alternative to threaded forums.

By contrast, I recommend against using annotation as a substitute for forum posts, and have endeavored to keep the system focused on annotation. Our research interest (that of the TextWeaver team) is in enabling students to construct (weave) richer dialogs, using annotation and smartcopy to reference other parts of a discussion (hence the focus on forums rather than documents).

Anyway, it’s all very interesting. I’m somewhat disappointed to discover I am not in fact unique, and surprised that all my searching the web for other systems didn’t turn this up before now. I only discovered HyLighter because it showed up in a search I subscribe to of all blogs mentioning web annotation. I suspect the reason for this can be traced to the fact that the HyLighter team has not open-sourced their software. Which is a shame, really.

  1. Previous