Skip navigation

Scratching my Flickr itch with Nitro

I have somewhat neglected my English speaking audience, I must apologise. I’ve recently moved to Taiwan to study Mandarin, and my travellers journal will mostly be published on the Dutch side of this blog.

Before I left to Taiwan my grandmother gave me a beautiful little camera, and I’ve been taking pictures like a madman and posting them to my Flickr account. I would like to include these pictures into my blogposts, but I would like to use a specific HTML template, so I can easily style them with CSS, like so :

Giraf schenkt David en Arne thee

Because of this the Flickr generated code and most other solutions out there are no good. Instead I decided to code up my own solution, scratch the old itch so to say. In the meantime you guys can enjoy a little example of a Nitro app in action. It’s a wee little thingy, but it shows that with Nitro you don’t get much overhead in your code. If you make a small Rails application, the noise to signal ratio is huge with so much pregenerated stuff you’re not gonna need.

So the target is just a single page with my most recent pictures, and next to that a text area that contains copy-paste ready HTML in my desired format. I coded this up in a small hour, with most time spent reading the Flickr API docs. I tried the flickr gem, but it’s no longer maintained and I couldn’t get it to work quickly, so I started my own wrapper just for the API calls I need. (YAGNI, right.)

The “app” is called Flikker (which is a not-so-polite word in Dutch BTW, wonder how many search engine hits this will bring me). Download it here Flikker v0.0 as a tarball.

To run:

  • in settings.rb fill in your Flickr API key and user name
  • adapt ‘launch’ to point to your Nitro repository
  • change conf/debug.rb if you want to use something other than mongrel
  • ./launch
  • visit localhost:9000 in your browser

Actually this is such an embarassingly small app I wasn’t going to put it out there, but it’ll be damn handy for me, so maybe somebody else has a use for it also.

3 Comments

  1. Posted September 5, 2007 at 13:22 | Permalink

    This looks very helpful for newcomers.

  2. Posted September 6, 2007 at 13:03 | Permalink

    Hi Ann,

    … yes :: it is quite a useful demo for Nitro and possibilities.

    As an instructional tool I would like to see (side-bar) links to “source code” Something along the lines of the fire-fox CTRL/U show source as an accellorator would be cool.

    A great teaching tool would be a link on each page to “well annotated source” with not too much help so that the learner needs to Read teh code and comments to see how it works.

    Great demo site … Love it.

    w.

  3. Posted September 9, 2007 at 18:44 | Permalink

    Hi Will,

    I’m not sure you got the point. _this_ site is a php-based wordpress site. The app in the article is a tiny Nitro example app. I coded it up for myself, and just made it available _as is_ in case it is useful for anyone. There’s another example + tutorial for Nitro that’s in the pipeline, which will be better documented.

    The name is Arne, BTW

Post a Comment

Your email is never published nor shared. Required fields are marked *
*
*