jQuery 1.5 adds better support for JSONP requests. As you might know, JSONP is a way to avoid the same-origin policy and do cross-domain requests by adding a method call around the JSON data.
Because browsers don’t return data from requests that fail, error handling is tricky compared to normal AJAX requests. There is a workaround by using a timer, which is the way the popular jquery.jsonp plugin solves it.
jQuery 1.5 adds this workaround, so you don’t need this plugin. All other features of the plugin, such as custom callback naming, are possible in jQuery now as well.
Here’s an example:
var req = $.ajax({
url : url,
dataType : "jsonp",
timeout : 10000
});
req.success(function() {
console.log('Yes! Success!');
});
req.error(function() {
console.log('Oh noes!');
});
The timeout parameter is essential, because this indicates when a request should be considered ‘failed’. Because of this extra parameter you need to use $.ajax instead of $.getJSON.
The req variable contains the jqXHR object, which can be used to attach multiple callbacks and error handlers.
CREATE YOUR DEBUT ALBUM COVER
1 – Go to “wikipedia.” Hit “random… Read More… Read More” or click http://en.wikipedia.org/wiki/Special:Random
The first random wikipedia article you get is the name of your band. (alternatively, if the first article you hit is short, hit Random Article two more times.)
2 – Go to “Random quotations”
or click http://www.quotationspage.com/random.php3
The last four or five words of the very last quote of the page is the title of your first album.
3 – Go to flickr and click on “explore the last seven days” or click http://www.flickr.com/explore/interesting/7days
Third picture, no matter what it is, will be your album cover.
4 – Go to You tube and type without looking-the first music in the search results is your bands hot new Indie release!!
**Alternatively you can ask people in the group to post music that sounds like a good match with your album cover.
5 – Use photoshop or similar to put it all together.
6 – Post it to FB with this text in the “caption” and TAG the friends you want to join in.
7 – Use this URL to invite people to this group so they can share their masterpieces: http://tinyurl.com/dh4bqr
A little known new feature of HTML5 are the <details> and <summary> tags. Combined, you can use these two tags to create a disclosure widget. Something you’ve probably seen before. Here’s an example from the Mac Finder:

Clicking the arrow next to ‘Devices’ hides or shows the ‘children’ under it. A very useful interface element. Until now, there was no standard for doing that (i usually used <fieldset> and <legend> to code it).
Unfortunately, it’s not supported in any browser (yet). But thanks to the power of jQuery we can make a very simple plugin that emulates this behaviour. My version is really simple, but if you need something more sophisticated check out @mathias’ solution.
Here’s an example.
Download the plugin from Github or copy-paste from below:
-
Placed on Monday 20-12-2010
-
No comments. Add one? »
-
Posted in english, ict+web
I no longer needed a reason for my existence, just a reason to live. And imagination, free will, love, humor, fun, music, sports, beer and pizza are all good enough reasons for living.
Brilliant article by Ricky Gervais on why he’s an atheist.
-
Placed on Monday 20-12-2010
-
No comments. Add one? »
-
Posted in english, links

I went to the Europeana Open Culture Conference in Amsterdam today. Fellow Wikimedian Liam Wyatt was doing a keynote on his time as the Wikipedian in residence with the British museum, and there were tracks on linked data, user generated content and the risks and rewards related to ‘freeing up’ content.
I’ve made notes on the first two talks in Markdown format, which can be found on Github.

I was at the Fronteers conference the past two days, which was really good. Check out the website in a week or two for videos and slides of all speakers.
During the lectures i took notes using Markdown, which happens to format to very nice HTML when pushed to Github. So if you want, you can read the notes for the conference from both day one and day two.
I’ll do a blog post with some highlights somewhere in the next couple of days.
-
Placed on Saturday 09-10-2010
-
No comments. Add one? »
-
Posted in english, ict+web