@madpilot makes

Get all this summer’s cricket action – via twitter!

Are you a Australian? Are you a cricket fan? Are you on twitter? If you answered yes to all of these questions, you might be interested in the Twitter bot that I just coded up. Using the fantastic cricinfo.com website, some Hpricot trickery, the Twitter gem and some Ruby jiggery pokery you can get a ball-by-ball commentary of the Aussies beating everyone in there path.

So head over to http://twitter.com/baggygreen and get your summer cricket fix!

How it works:

  1. I used the WAP version of the cricinfo website, because the HTML is much simpler to deal with. First I find all games that Australia are playing. The front page has a list all all games in progress. Doing a string comparision, I grab the URLs to any Australian games.
  2. Using Hpricot, I parse the HTML from the commentary page, pulling out the score, overs, balls and commentary using X-path.
  3. I keep track of what I’ve already posted in a text file. Any new comments are posted to Twitter. If the script detects the end of an over, the score is posted as well.
  4. The script runs as a crob job every 5 minutes

Nice an easy, eh?

Update: Download the code! Excuse it’s less than optimal solution – it was hastily written :)

ByteMe!, PerthMassive and Freelancer Friday – take me where the web goes.

We are hurtling into the wacky end of the year – before you know it, we’ll all be drinking egg-nog and having seedy older men/women hitting on us at office Christmas parties (or vise-versa if you are said seedy man/woman). Well to celebrate, the Perth digital content community is throwing some awesome events over the next couple of weeks: Namely ByteMe! and PerthMassive,

ByteMe! is the brainchild of Kat “I must be taking something because it is impossible for one person to do the amount of stuff I do within a 28-hour day, let alone with in the bounds of current time” Black – it is a free week-long festival that will be show casing the best 1’s and 0’s of the Perth digital community. Not only that, there are some pretty god-damn kick-arse speakers (See for yourself). It it December 2-9 and did I mention free? Oh and AWIA will be running a BarCampNano on the Sunday from 1-4pm – so if you have anything you want to show the world in 20 minutes or less, rock up between those hours to the Perth Town Hall.

Speaking of AWIA, please note that there will be NO Port80 in December because of the biggest digital Christmas party this side of Omnicrone-4, Perth Massive is on! So free up your schedules for the 6th 4th of December 2007, and head over to the Library in Northbridge (The niteclub, not the repository of books) and meet-up with others that like to do what you do (Unless what you like to do is macrame – unless the macrame usergroup shows up). Also free. Free as in beer. And there is Free beer. Which is free as in – beer. Make sure you go and register though, so the organisers knowhow much free beer to get.

Oh, whilst I’m at it, We are having the next installment of our exciting Freelancer Friday initiative at the Silicon Beach house on Friday 30 November 2007. We had about half a dozen people last time which was awesome and since the last one have knocked down some walls and stuff (shh, don’t tell the landlord) so there is heaps more desk space now. If you are interested, drop me an email, or throw your name on the Work@Jelly wiki under Work@ Jelly Perth – Freelancer Friday.

So get your dancing frocks and red (Reebok) pumps and lets rock this Popsicle stand!

I prefer begin called a geek, but what the hey…

Anyone that has to interact with geeks/nerds/sith masters – PLEASE READ THIS FIRST.

Absolute gold. Scarily true.

Facebook, OpenSocial – meh. Why aren’t widget useful?

Widgets are a hot topic in the world of social networks and blogs, but at the end of the day they really don’t make our lives better. I mean honestly, if all of those widgets out there stopped would we miss them? Hell, some of them are down right annoying. The IDEA of a widget is not as dumb as some of these apps, but for some reason they haven’t been embraced by those developers that are helping us to get things done.

Google has just released OpenSocial, and I was admittedly pretty excited – for about 5 and a half seconds at which point I realised it would have limited scope outside of the social networking world (hence the name). Why was I excited? Well I would love to be able to create a widget for 88 Miles – imagine being able to drop a time-tracking widget into BaseCamp or NetAccounts or ? Or, even better, into your internal intranet.

OpenSocial has so much potential, but isn’t quite there for the Software as a Service guys, so why don’t we create a an Open Widget API? What do we need? Well, not that much – if we flip the way that OpenSocial works a little and do a little work from the application side.

JavaScript, JSON and HTTP

The easiest way to drop your widget on to a third-party site would be JavaScript. Create a standard JavaScript end-point that the third-party app can retrieve. Maybe it could pass in a element id that you could use to build your DOM tree from. Because the script is hosted on YOUR server, you can make calls back to your server via AJAX. You can use this to generate HTML, make callbacks, retrieve JSON and generally interact with your database.

This is SO easy with Rails, as you can get a JSON REST API out of the box, with very little effort. PHP/Pylons/ASP.NET will do the same thing easily enough to. Extend that idea, and with a little knowlegde of the site you are embedding on, you could probably even interact – add a company to your Basecamp account and it would automatically add it to 88 Miles. You could do it by registering observers of specific types maybe – not sure, will still have to think that bit through.

Authentication

We already have a system for authentication – it’s called OpenID. If your site implements OpenID, it is pretty god-damn trivial to authenticate a user that has already authenticated on the third party site. Any OpenID provider worth it’s wait will remember your credentials once you have logged in – so the third party site can pass your OpenID URL down to the widget, then you can authenticate them from there, and because your provider has already logged you in, you won’t need to enter a username or password.

The ultimate mashup

If all of your favourite apps had these widgets, you could easily drop them in to your intranet site. How kick-arse would that be? What do you think?

New version of Twitteresce available

After a long hiatus from development (I’ve been busy ok!) I’ve just released a new version of Twitteresce – a mobile client for Twitter. New features include:

  • The ability to delete your tweets and direct messages
  • A correct “sent from” string on the web site version
  • Other small bug fixes

So point you mobile browser at http://www.madpilot.com.au/twitteresce and download version 0.9.

String theory explained in two minutes

Well I’m convinced

AWIA’s very own OpenID server

I just deploying a new version of the AWIA website, which adds an OpenID service provider – so now AWIA members can use their member username and password to login to any OpenID-enabled website.

OpenID is a de-centralized authentication standard that allows you to use one username and password across any site that supports the standard. It can also send common information such as email address and username. The number of sites that support OpenID are steadily rising, which is why I added these functions to the site.

It is all very easy – login to your http://app.webindustry.asn.au/members/login click “Your details” then “Edit”. There is a new field labelled username. Enter a username here and then, when you come across an OpenID enabled site, just login in to http://app.webindustry.asn.au/user/[username]

Easy as you like it!

Podcamp racetrack’s in 10 days’ on

(Mental note: Work on better blog post titles)

Annnyway, as many of you know, Podcamp is coming to Perth on the 28th and 29 of October. A little birdie and my scouta on the ground tell me that we are getting some big names from over east to participate in this Australian first.

Now, there has been a bit of confusion over what can be presented at Podcamp – it isn’t just about Podcasting. Anything that fits in the realm of new media (I know – I hate that term too, but I haven’t got anything better at the moment) would be a worthy topic.

There will be shirts available on the day. It’s going to be a great couple of days, so make sure you mark em down in your diary.

Blogging for Sitepoint

Is blogging about yourself blogging like Googling yourself? Whilst you ponder that thought, I should point out that there are a number of Perth web-types blogging for SitepointKay Smoljak is making Coldfusion cool again, Miles Burke is blogging about something (still waiting for your opening post Miles…), oh and some [hack][5] is writing about [Ruby on Rails][6]…

If you have any suggestions drop one of us a line!

[5]: “It’s me fool!” [6]: http://www.sitepoint.com/blogs/2007/10/15/ruby-on-rails-the-art-of-simplicity/

And all that Meraki…

These little networking devices have created quite a stir amongst the twitterati over the past couple of days, even enough to make Lachlan Hardy revive his blog! :P

Anyway, as he mentions I’m taking some orders for any Perth peeps that would like a couple. The more people we get, the cheaper the shipping is (the shipping on one unit costs $US50 – 13 units, it come down to $US10 a unit – mob rules!).

Go check out Lachlan’s post for the low-down on what these things can do. If you want a couple, drop me a line – I’ll be getting them on Friday, so chop, chop.

Previous Next