Archive for January, 2008

LiveJournal Comments

Monday, January 28th, 2008 at 7:47 pm

Once upon a time, JR recommended that I write a script to pull comments from my blog’s syndicated account on LiveJournal into Movable Type, so that all comments would appear in one place.

And I did, and all was well for a while, but the recent upgrade broke it.

Well, it’s fixed now. Not a big deal, really, but all comments will be copied here every now and again when I run the script and approve them. Futhermore, you LJ folks can now comment on my actual site with your LiveJournal account. If you’d rather do that, click the link at the top of the post in LJ, and use the Sign In link below comments that have already been made. LiveJournal is one of the options on the right side.

Or, just comment on LJ. Either way, I’m stealin ur thoughtz.

Heroic

Monday, January 28th, 2008 at 2:38 pm

I can no longer listen to music without imagining how I would play it on a color-coded plastic guitar.

Police go back to basics to tackle Shaw crime

Monday, January 28th, 2008 at 12:48 pm

From Examiner.com:

To combat the street gangs warring in Shaw, 3rd District police are going back to basics: Foot patrols are visiting with 10 residents a day, officers are taking names of suspicious people, and roll calls are being held outdoors as a show of force. On Friday afternoon, a dozen D.C. police officers formed a blue line on the corner of O Street and 7th Street Northwest, between two large, boxy public-housing apartments. Stern faces peered down from the windows.

7th & O is about four blocks from my apartment. Thankfully, we’re on the southern edge of Shaw, at the fringe of gentrification that’s brought nicer condos and lower crime rates, and most of the places we go are in the other direction. Unfortunately, my old roommate was mugged a few blocks away last month - not far from the police roll call, actually. We still try to avoid going north later in the evening, but the grocery store is up that way. The comments on that article make it sound like previous efforts like this one haven’t gone well, but I’m hopeful that our neighborhood will continue becoming safer.

Books That Make You Dumb

Saturday, January 26th, 2008 at 9:42 pm
Ever read a book (required or otherwise) and upon finishing it thought to yourself, “Wow. That was terrible. I totally feel dumber after reading that.”? I know I have. Well, like any good scientist, I decided to see how well my personal experience matches reality. How might one do this?

I came across the Booksthatmakeyoudumb project thanks to Kottke, and it’s pretty entertaining. Virgil Griffith compared the top 10 favorite books for college’s on Facebook to the average SAT scores for those colleges. On the high end, you’ve got Catch-22 and Freakonomics. On the low end, The Holy Bible and “I don’t read.”

I found it interesting to look at the list of schools. RIT is number 183, in average SAT score, but I was surprised to see that The Bible is the top book for the school. If you’re logged into Facebook, you can see all our stats and learn, like I did, that Boondock Saints is the most popular movie at RIT.

Three Years of Blog

Friday, January 25th, 2008 at 10:45 am

Check it out, I started this thing three years ago. Happy blogiversary to me!

Man Purse Lust

Thursday, January 24th, 2008 at 8:17 pm

People sometimes refer to 43Folders and Lifehacker as productivity porn, but today I found something on Lifehacker that’s much more exciting to me: man purse porn. They call it a Go Bag, but we’re talking about the same thing: the bag of crap you take with you everywhere (except, they don’t specify that it’s for men). I’m pretty sure that “be prepared” is the only thing I took away from being a Boy Scout, because I like having a lot of stuff handy.

The messenger bag I’ve been using for the past 4+ years has almost completely fallen apart, so I’ve spent months obsessing about finding a suitable replacement. As it turns out, I’m pretty particular about my man purse; I bought this one from American Eagle’s website and completely lucked out, and now that I’ve known man-purse-perfection, I don’t think I can ever look back. In fact, I’d buy the same one again, but they seem to have discontinued it.

I’ve been poking through their galleries, looking for bags that might work for me. It needs to be big enough for my MacBook, a couple books, and some other stuff, but I don’t want it to be TOO big; I need the Goldilocks bag.

I’m a picky bitch. If you’ve got a bag you love, let me know so I can check it out.

Movable Type: Update Entry Date

Thursday, January 24th, 2008 at 8:05 pm

My favorite plugin in MT3 was UpdateAuthoredOn. It didn’t do much: you got a button next to the entry date input, and clicking on it would update it to the current time and date. Simple, but very handy - especially if you’re the kind of person who writes an entry over the course of a couple days and want to post it with the current time.

The new version is called UpdateEntryDate, but it’s not working for me in MT4. So, I ripped out the part I needed and changed the MT template. If you want to try it out, you’ll need to modify tmpl/cms/edit_entry.tmpl in your MT directory. Go to line 1057 (give or take), or search for entry-time to find the date and time inputs.

First, the time input needs an ID. You can replace the whole entry-time input with this:

<input id="entry-time" class="entry-time" name="authored_on_time" tabindex="11" value="<$mt:var name="authored_on_time" escape="html"$>" />

Then insert this two lines down, after the closing span tag:

<input type="button" class="primary-button"
onclick="update_authored_on();" value="Update" />
<script type="text/javascript">
function zeropad(num) {
return (num < 10) ? '0' + num : num;
}
function update_authored_on() {
var now = new Date();
var y = now.getFullYear();
var m = zeropad(now.getMonth() + 1);
var d = zeropad(now.getDate());
var h = zeropad(now.getHours());
var min = zeropad(now.getMinutes());
var s = zeropad(now.getSeconds());
document.getElementById("created-on").value = y + '-' + m + '-' + d;
document.getElementById("entry-time").value = h + ':' + min + ':' + s;
}
</script>

Movable Type: Archives Location Change With Upgrade

Wednesday, January 23rd, 2008 at 10:19 pm

As I’ve mentioned here before, I upgraded to Movable Type 4 not too long ago. One of the changes that almost went unnoticed is the way archives are handled. In MT3, I wasn’t using the dynamic pages, so every post was generated into a file in the archives directory. For example, a post about new music in July wound up at /archives/2007/07/new_music.php.

In MT4 - or at least, MT4 with dynamic pages - there is no archives directory. Really, there aren’t any directories, since it’s all handled by mod_rewrite, but that’s not really the point I’m making. Under MT4, that post I mentioned above would be at /2007/07/new_music.php, with no /archives at the front.

Now, I could change the Archive Mapping on the Entry Archive Template in the admin, but I kind of like the shorter URLs. I don’t know much about mod_rewrite, but I found an answer a lot quicker than I expected to, thanks to askApache. I just added this to the .htaccess file in my site root, and now any requests to the non-existent archives directory are re-directed back into the root.

RedirectMatch ^/archives/(.*)$ http://www.brockli.com/$1

If you want to use this for your site, you’ll need to replace brockli.com with your own URL, but that should be it.

iPhone: iPod Controls In Standby

Wednesday, January 23rd, 2008 at 6:21 pm

I discovered this by accident this afternoon when I was wiping off my screen.

With the screen of your iPhone off, hit the Home button twice. iPod controls come up on-screen.

I usually use the clicker on the headphone wire when I’m using my phone as an iPod, but you can’t just plug in the headphones and click the button to start playing. It also seems to “forget” you were listening to music if you pause it and do anything else on the phone. Until now, I thought you had to tap the iPod icon and navigate back to what you had been listening to. This little shortcut is pretty handy, methinks.

Schoolbus RV

Tuesday, January 22nd, 2008 at 11:57 am

The MAKE Blog has a video of Jake von Slatt describing the RV he built in an old school bus. He seems like the kind of guy that will make an awesome grandpa someday. Check out the video: Link.