Showing posts with label script. Show all posts
Showing posts with label script. Show all posts

Monday, 5 November 2007

Films list is back

Rather than pollute and bore people with films list in my blog (I'd rather do that with useless trivia, and self-deprecation), I thought I'd use IMDb's My Movies feature.

The hardest part was getting all the films from a variety of sources into the database, without having to click through all of them. Here comes the Mechanizer (in US English in the text). Given a list of @imdb_ids:

my $mech = new WWW::Mechanize;
$mech->get( "http://www.imdb.com/register/login" );
$mech->success or die "Can't get the login page";

$mech->submit_form(
form_number => 2,
fields => {
login => 'email@test.com',
password => "mypassword",
},
);

my $id;
foreach $id (@imdb_ids) {
print "Adding $id\n";
$mech->get ("http://www.imdb.com/rg/title-lhs/mymovies/mymovies/list?pending&add=$id");
}

I used my old code from film-gallery.pl code to grab the IDs from blogs, and various types of files. HTH.

Sunday, 2 September 2007

Random links

Jeez, I'm bad at blogging.This afternoon's footie game brought up some interesting new connections. But after watching MOTD, Philip pointed me to this bug. Peculiar choice of videos to watch.

I've also written a small bookmarklet so that I can swarm (mugshot parlance) with Epiphany. And my VAIO's gone.


A year-old picture, FIFA isn't quite tuned up for my first season as a manager