Feed Me

Wow!  I am typing this into the “Visual” tab on WordPress in FireFox 3.5 and dang is it noticeably faster.  To clarify, I installed Ubuntu 9.10 (Karmic Koala) on my EEE 901 and thus have gone from Firefox 3.0.X to 3.5.X.  Browsing seemed snappier, but now I know it’s magnitudes better based on how this is performing.  Previously I could practically watch the characters appearing, now they feel like they’re there before I finish hitting the keys.  This is awesome!

I’m also trying AdBlock Plus instead of NoScript to see how well it fairs.  NoScript is great, don’t get me wrong, but sometimes it takes me a moment to notice I’m missing something on a web page.  Some sites require JS for form submissions and things and you won’t know until clicking a button does nothing.  So I’m hoping ABP will use up less of my brain cells.

It’s the end of another week, this one kinda fell off the edge at contracting job.  That is, I started to run out of things that needed doing and didn’t feel like wasting my time and their money by sitting in a cubicle sopping up their cash.  Instead I mostly worked half-days and played Dragon Age or read The Gathering Storm in the evenings.  No programming, but I have been adding posts to Bikini BOP here and there (always a fun activity).

What I’ve been meaning to do, as a smallish activity, is rip out the last of the PHP code I have that requires Zend Framework, specifically the Feed classes.  In true perfectionist fashion my biggest stumbling block has been what to name the class and its file.  Dumb, right?  Well, I started with XmlFeed (xmlfeed.php) but that sounded too generic and you wouldn’t necessarily know what it does at a glance, so I’ve switched to Rss (rss.php).  Too obvious?  Oh well, I tried.  It will read Atom feeds to an extent as well, but it will basically boil it down to the same components as RSS.

Another quirk, since I’m writing this for myself, I found myself designing all the property names (these will be array keys) as 4 characters.  What’s that called?  Not OCD, well not really.  My mind was more of in a puzzle-solving and creative mood: how can I make these mostly apparent but keep them in 4 characters?  It’s a little crazy too, I admit, but here’s what I came up with:

  • name: <title>  This one isn’t great, but it still makes sense.
  • uuid: <guid>  I could have gone with the latter, but other parts of my code (GData class) had already used UUID and I thought I’d keep it the same.  In fact, I copied all these except “from” from their usage in my GData class.
  • body: <description>  Following a sort of “email message” motif, huh?
  • date: <pubDate>  I’m working exclusively with published dates so all others are ignored.
  • href: <link>  Specifically the HYPERTEXT reference (e.g. link to a web page).  For Atom feeds this will find that HTML link which for my purposes is what I always want.
  • tags: <category>  Nothing much to say here except that I drop all the fluff around categories and just keep their names.
  • from: <author>  This is my favourite one!  I didn’t want to use “auth” for fear it would be confused with “authorization” or “authentication” (as I commonly use that abbreviation).  Since a name and/or email address goes in this field, it continues that email motif I mentioned earlier.

So as soon as I have the urge, I’ll be plopping this into ObremSDK and get FanSiter running on this netbook where I don’t have (and didn’t want to download) ZF.

Leave a Reply