Friday, January 14, 2011 03:41 PM
Better Tweeting of Cops Now Available
 by Fëanor

Mike V. was good enough to do extensive testing of the Twitter feature I added to my random cop movie premise generator, and pointed out some flaws. Well, I've finally gotten around to addressing them! All tweets generated by the app will now be automatically cut down to 140 characters or fewer (which only makes sense), and, even better, the link provided in the tweet will now take you to a version of the "They're Cops" page with the field at the bottom pre-populated with the particular "They're Cops" phrase that you found so amusing. So no one will have to guess at what it was that you found so funny. Yay!

Interestingly enough (well, interesting if you are technically inclined at all - non-developer nerds may want to step away now), in order to make this work I actually had to change the URLs on my website. I'd been using a vertical pipe in various URLs as a divider, but it turns out the Twitter API really hates vertical pipes. It was accepting the encoded version of the character the first time through, but then for some reason it was double-encoding it the next time through and posting an unusable URL. I probably could have kept banging my head against it until I got it to work, but instead I decided to take the easier way out and just replaced vertical pipes with commas in my URLs. The old vertical pipe-using URLs will redirect to the new comma-using URLs, in what I hope is a seamless change.
Tagged (?): Internet (Not), Meta (Not), Twitter (Not)

<< Fresher Entry Older Entry >>
Enter the Archives
Back Home
Welcome to the blog of Jim Genzano, writer, web developer, husband, father, and enjoyer of things like the internet, movies, music, games, and books. For a more detailed run-down of who I am and what goes on here, read this.

RSS icon  Twitter icon  Facebook icon  Google Plus icon

Advanced Search

Recent Entries

Recent Comments

Most Popular Entries

Entry Archive


RSS Feeds
  • Main feed: RSS icon
  • Comments: RSS icon
  • You can also click any tag to find feeds that include just posts with that tag.