This code takes a random entry from my movabletype blog archive and diplays it. You can see it working here http://idiolect.org.uk/notes/random_entry.php