December 29, 2003

How to limit comments to one week after posting

I've been thinking a lot recently on the issues we'll be facing as blogging continues to grow and be successful. One of the spam fighting tools (metaphor: club, not lojack) I implemented was a restriction on comment posting to posts that have been created in the past week. A few people have written and asked how I implemented the time restriction on comments.

It is actually very simple, once you've got a SQL backend (see previous post) for your blog. Here's the script I have running out of my crontab:


use DBI;

my $dbname = 'DATABASENAME';
my $hostname = 'localhost'; # Change this if the db is on another box
my $dbuser = 'DBUSER';
my $dbpass = 'DBPASS';

$dbh=DBI->connect("dbi:mysql:database=$dbname;host=$hostname", $dbuser, $dbpass);

$dbh->do("update mt_entry set entry_allow_comments='0' where entry_created_on < date_sub(NOW(),interval 7 day)");

I run this every hour. Basically, it makes a single SQL call, which updates the entry_allow_comments column on mt_entry to turn off comment posting on entries that are older than 7 days. Use and enjoy.

Posted by dsifry at 9:37 AM | View blog reactions

Morning feed bugfixes

Thanks to an astute reader, I've restored full entries to my RSS feeds (RSS 1.0 and RSS 2.0 - the Atom feed already had the full text by default). Subscribe with impunity.

Posted by dsifry at 9:36 AM | View blog reactions

December 26, 2003

Revamped Blog design

I can't believe it - I actually had a few hours today to work on the weblog. There's been so much going on lately that just about the last thing that I've had time to do was work on the blog, write a new entry, or play with some new software (heck, I was still running MT 2.21!)

So, enjoy the new site. I tried to keep things looking about the same, but there's a lot changed on the backend, and some new features available:

  • Technorati Integration (using Adam Kalsey's Technorati Plugin)

  • Snippets sidebar mini-blog, powered by, and some fun RSS hacking

  • ATOM feed, RSS 2.0 feed, RSS 1.0 feed

  • MT-Blacklist to kill off all that nasty blog spam. Man, it was getting nasty!

  • Disabling comments after the post is older than one week old. Sorry, if you don't like it, post on your own blog.

Anyway, those are just a few of the new features. I also put the entries into MySQL so it'll make a whole bunch of scripting/munging easier as well. I hope that this'll make it easier for me to blog more again, but I'm afraid that the bigger issue is lack of time. Soooo busy busy busy...

Posted by dsifry at 6:03 PM | TrackBack | View blog reactions

A quick w.bloggar test

Just testing out some new improved ways of posting to the blog.

Posted by dsifry at 5:38 PM | TrackBack | View blog reactions

December 10, 2003

Giving Thanks (a very abbreviated list)

Well, it is 4:30AM and I'm completely awake - bright and bleary-eyed This has been a tough few weeks, with both kids getting the flu (or something like it) - and they got it consecutively - first Melody, which knocked her out for a week, now Noah, who is busy snoring away in the swing because that's the only place where he gets any rest. Poor bugger, he can't even blow his own nose yet, so he's just plain uncomfortable.

This leads me to something I've been thinking a lot about lately, especially given the holiday season, and that is giving thanks. I learned a long time ago that having an attitude of gratitude is by far the most healthy thing for me, and especially in these somewhat difficult times of newborn bliss, giving thanks is a great way to remeber just how lucky and blessed I am. I was hoping to get this out for Thanksgiving, but better late than never, and as anyone who knows me well knows, time management isn't my strongest quality. :-)

So here goes. In no particular order.
  • My wife and kids, just for being great.
  • The rest of my family, parents, siblings, aunts, uncles, cousins, nieces, nephews, everybody.  Thanks for your love and support.
  • All the folks at Sputnik - Dave, Art, Kathy, Scott, Tom, Bryan, Tony, Jeff - Kudos guys.
  • All the folks at Technorati - Dan, Kevin, Mike, Kriszti, Louis, Brendyn, Theresa - you folks rock.
  • Dan Gillmor, one of the few voices in mainstream journalism who consistently does great reporting on technology, media, and civil liberties issues
  • Steve Gillmor, tireless supporter for metadata and new journalism business models
  • Dave Winer and the folks at Userland for setting up, the granddaddy of the pinger sites.
  • Not to mention all the standards backed up by real money (and bandwidth) that Dave provides. Thanks, man.
  • Doc Searls - a constant voice of sanity, wisdom, and good judgement. And the best knack for writing weblog/article titles I've seen.
  • Jason DeFillippo and his wonderful Blogrolling service.
  • Ben and Mena Trott for producing great tools
  • The USA.  Yeah, even though this country isn't perfect (and right now, we're going through one of those periods of collective insanity), it is still a great country, and I'm grateful to be living here - only by accident of birth - rather than in one of dozens of incredibly repressive, war-torn, or dirt-poor countries.
  • Evan, Steve, Jason, and the folks at Blogger
  • Linus and the hordes of open source programmers out there adding to the collective codebase.  Thanks.
  • The EFF, for its tireless work and fight for our civil rights in cyberspace
  • Larry Lessig and the folks at Creative Commons, fighting to preserve the public domain and our collective heritage
  • Brewster Kahle and the folks at the Internet Archive, adding a Library of Congress every few months can get wearing after a while, thanks for doing it.
  • All you bloggers - who (a) help inspire and inform me, and (b) help make my current business possible.  There is a rebirth of civics going on, and you guys are making it happen (as well as posting great kitten photos)
  • Yahoo, Google, the New York Times, AOL, the Mozilla Project, the Apache project, the list goes on and on. Thanks.
This just starts to scratch the surface of the list. I am so lucky to be alive and to be right here, right now.

December 9, 2003

Sputnik-Claus is Coming to Town

Just in time for the holidays, a new promotion from Sputnik: the Sputnik Quick Start Kit (buy). The program runs from now until the end of the year. A perfect stocking stuffer for that hot spot on your holiday shopping list!

Sputnik Quick Start Kit - includes:

  • 2 Sputnik AP 120s
  • 1 Sputnik Central Control License for 2 APs

Sputnik Holiday Promotional Price - $455 (normally $1,265) - less than the price of some high-end APs whose names I won't mention!
If you want to upgrade to the full 20-AP license (normally $895) you can do that later, for $485 more - a 25% discount.

All of the details are up at: