Flickr Feed Gallery: A Quick Hack for DS106

All images courtesy of various DS106 Internauts.

Image of two dolls
Image credit: spur_dotz’s “Ash and Ichabod”
Thursday night’s class started in one direction and ended up in a whole ‘nother one. It was pretty fun, well, at least for me. I was planning on talking about image stories, because we have been working on photography assignments all week, and were starting to think about image stories. But then the opportunity arrived to talk more about RSS feeds, Flickr, WordPress plugins, and hacking theme templates, and I couldn’t resist—I felt like an instructional tehcnologist again, a real EDUPUNK, so I ran with it 🙂

The entire class was asked to tag their photos on Flickr with two tags, ds106 for all their photos for the class, and then a tag for each day’s Daily Shoot assignment, i.e., dailyshoot1, dailyshoot2, all the way up to dailyshoot8. They had done that before coming to class tonight, and I noticed about half of the images the class took showed up in each of the feeds for the eight dailyshoot tags. For example, the dailyshoot1 tag only has 19 images, which means about 8 or 9 were missing. Same was true for most of these tags. Still trying to figure out why so many are missing, especially when the class had tagged them correctly, I wonder if it has anything to do with the Flickr RSS feeds capping at 20 items—though the http://www.flickr.com/photos/tags/dailyshoot1/ doesn’t lead directly to an RSS feed, so I am stumped.

Image of ice cream
Captureme45’s “Untitled”

Anyway, each of these tags still has a feed, and looking at that provided a way for me to demonstrate more specifically how plugins work in WordPress. We installed the Flickr Feed Gallery, which is a simple plugin that pulls in specific photos based on Flickr feeds. So we started experimenting with this as a way to pull in the class photos we tagged to the sidebar of the course blog. And what was amazing, is that just about everyone in the class had also installed this plugin on their own blog with a quick search and click from within the WordPress installer. So within seconds, they almost all had the plugin up and running. And given it was all so easy, it just made me want more! Especially when I saw the plugin description:

Enables easy integration of Flickr photo feed to a WordPress blog. Configure feed parameters from settings page. Use in your theme or add plugin as a Widget.

That little bit of PHP code got me thinking, why not show the class how to hack a theme in WordPress. I mean plugins were easy, search and installing themes is a cinch. So why not turn to the actual theme files in the editor and have them add that bit of PHP code to get a sense of how templates work. Or better yet, have them create their own page template, add the PHP code, and then upload it to the theme file in wp-content. They have file manager from CPanel, it should be a breeze. And there went the rest of the class 🙂

Image of rug
Image credit: Apeterso’s “Untitled”

And while a bit risky, it was invigorating. An occasion to have the whole class hacking WordPress themes, making Flickr galleries in a page on their blog. Kind of a dream come true, I mean it is that very hacking that got me my job at UMW. It’s good stuff, and I think it will beget more curiosity in those who already have an inkling but have no sense of what some shared web hosting space and open source application can expose them to.

Image credit: c-hamp’s “Reflective Shades”

So, anyway, we got to the Appearance–>Editor section in WordPress, and I realized I had to get off the course blog on UMW Blogs and head over to the bava in order to demonstrate how the themes work and try and briefly explain what’s the deal with CSS, header,php, page.php, etc. So, I switched bava’s theme to TwentyTen because K2’s code is too bizarre for a good demonstration. And then asked the class if anyone knew anything about CSS because the first page that comes up when you go to the theme editor is stylesheet.css. It became a opportunity to talk about the emergence of CSS, what it means in relationship to dynamically created content using PHP and MySQL, and explain how the themes in their blog were actually theirs to hack. I was surprised how few of them knew anything about CSS. And I tried capturing that in broad strokes, but I may have to revisit this again. I might talk to Zach Whalen, and see what his CSS assignments entail for his Writing through Media course–cause I could use some tips in this regard.

Imaeg of man with books balanced on head
Image credit; KC_Masterpiece’s “Learning by Osmosis”

Anyway, after that I explained how the template-driven theme works, what header.php, footer.php, index.php, and page.php do. How these scripts work together to dynamically create pages, the styles of which are defined by CSS: a virtuous cycle. And after that, I demonstrated how you can copy the code from the page template to a text editor, and then create your own template locally, rename the template something like Daily Shoot 7 and the PHP file something like dailyshoot7.php. After that, you upload it to you wp-content/theme/your_particular_theme directory. Finally, it should become an available template in the dropdown menu of any page you are creating, and with that bit of code from Flickr feed Gallery place right beneath the the_content PHP call, you should now see the Flickr Feed Gallery of images in the page you assigned this template. For the most part they got it, but there was some lumps, and about 4 or 5 people stayed after class for upwards of an hour to get some more details, fix their site, and walk through the process in more detail. Hence this post.
Image of a pig in a pocket
Image credit: edmz99’s “The thing that should not be.”

Here is what we did:

We copied the code from TwentyTen’s One Column Page template (I used this template for demonstration purposes) to a text editor on our desktop, something like Text Wrangler for Mac users (cause Text Edit sucks all you Mac fanboys and girls). For the PC, Notepad was more than adequate.

After they had the page template code copied into their local text editor. We changed the name of the template. For example,

/**
* Template Name: One Column Page
*/

Became this:

/**
* Template Name: Daily Shoot 1
*/

This simple change (or addition for many given they were using themes other than Twenty Ten) Actually renames the templates you you can see it in the Template drop down box on any given page you create in your WordPress blog.

After that, they had to find the he_content PHP call in their page template code and add the following line beneath it:

Once that’s done, they saved the template file to something like dailyshoot1.php and then uploaded it to their theme folder using File Manager in CPanel.

Finally, they head over to their blog and create a new page and select the template titled Daily Shoot 1 (remember we are creating a page not a post, posts don’t have individualized templates).

Imaeg of raman chaos
Image credit: b4ssm4st3r’s “Daily shoot: chaos”

Ok, so that was it for the basic hack the class was asked to do in class Thursday night. And those steps will hopefully act as a quick refresher and guide to anyone who had issues making it work. But after playing with Flickr feed Gallery I came up against some of this plugin’s limitations. So I wanted to play with it more. You see, for the course blog I wanted the Daily Shoot assignments to have their own tab in the header nav menu, and then have each of the eight daily image assignments feed into their own page within the menu item—each of which show up in the drop down menu. But the plugin was not designed for this, you could really only set the parameters for tags, how many images, what type, etc., globally in the plugin settings from the plugin interface under the Settings tab. Which meant, no matter how many times I pulled in the call into different templates, it would always pull in the same images for every page because the settings were global. And after some trial and error I couldn’t figure out how to pass specific parameters into the flickr_feed_galler PHP call I put into each of the eight different Daily Shoot page templates (one for each assignment). The fact I failed here shouldn’t be necessarily surprising because I am not a programmer. But, turns out I know a few. I asked Michael McManus of the great Cast Iron Coding outfit to look at this plugin and perhaps give me some advice on how I could pass specific parameters within the PHP call itself. Well, given he is a programmer, and a good one, he came up with the solution. What you need to do is change the code in the flickr_feed_gallery.php file of the Flickr feed Gallery plugin to this (I would explain the difference in the two versions of the code, but that might be another post, and one I will fumble through). What this will do is allow you define the specific tag and number of photos you want the to include. For example, if I put the following code in a specific page template:

What would show up is 30 images from Flickr tagged with dailyshoot5. So bam, I have the ability to customize each of the Daily Shoot assignment templates 1 through 8 by passing specific variables into this Flickr Feed Gallery PHP call, which will allow me to feature just that days assignments. You can see this at work on the DS106 course blog under the Daily Shoot menu item.

Image of jewelry
Image credit: les.epinards’ “Treasure Chest”

All that said, I had a couple of problems with this modification to the plugin, all which stem from the fact that in order to get more than 20 items pulled in from a feed on Flickr you need to get at the API, and do some custom queries. Given that, I can only show 20 of the 29 images on any given day. What’s more, I can’t show all 250+ images over the course of the assignments on one page as a kind of uber gallery. If I new how to program custom queries and get my hands dirty with the Flickr API I certainly would, but as of now this is a bit beyond me. And having said that, I was hoping for one of two things. 1) That someone out there might have a clue of how to pull in more images with the Flickr Feed Gallery plugin by messing with the Flickr API. 2) Someone might be abe to point me to a plugin that does this all already.

Imaeg of symmetry
Image credit: b4ssm4st3r’s “Daily shoot: symmetry”

Either way it was an experiment with hacking that might actually turn into a feature this class could use, and the ds106 internauts could experiment with creating a custom template in WordPress, hack it, and even modify the code of a plugin in order to get functionality that is not out-of-the-box. Either way, i hope this diversion pushes the class to experiment more with the tools they have at their disposal, and to try and break things so that they can put them back together, and really get a sense of how this open source application that they’re administering through their own web hosting space works. In other words, some sense of how the web works beyond drag and click.

Posted in digital storytelling | Tagged , , , , , , , , | Leave a comment

Daily Shoot: More interested by the lines inside

Image of stack of books

Today’s Daily Shoot assignment:

Make a photo of an interesting stack of books or magazines. Consider how you handle repeating lines in your composition.

Today’s shot is not too inspired, but I really didn’t have much time to take it, nor did I have the right light in my den. This is a series of books on the top shelf of one of the several built-in bookshelves in my new house (well, maybe not so new given we’ve owned it for a year this week). But at the same time, it feels new to me, and the built-in bookshelves are some of its nicest features, but I wasn’t up to capturing them adequately. So we’ll have to save that for another day. In the meantime, here’s my final daily shoot assignment for the section of the class on photography and visual storytelling. Now I just have to highlight my favorite shots from the whole class in a post sometime this weekend, and then on to audio stories.

I’m going to continue the daily shoot assignments because they really help me see things anew. I probably won’t post them regularly on the bava, rather I’ll send them right to Flick. Having the camera poised any given day is a habit I’d like to foster, and this past week has been a great exercise in training my habits of seeing

Posted in digital storytelling | Tagged , , | 2 Comments

Daily Shoot: 1212

Daily Shoot image capturing symmetry

Symmetry can be calm and soothing. Make a photo today featuring symmetry, either in subject or composition. (@logista)
dailyshoot.com/assignments/312

I’m fired up about today’s shot, and not so much because the image is so beautiful—though I like it—but because 12 is my lucky number, and two twelves in a row? Doubly lucky. My cat is named 12, and if it were up to me my first born would have been named twelve, and my birthday falls on the twelfth day. More than that, 1212 is an anagram for 2112 which makes me think of Rush, which then makes me think of Andy Rush. There is a lot to both this image and this number, obviously. Symmetry is just the surface.

Posted in digital storytelling | Tagged , , | 3 Comments

Daily Shoot: Green Maelstrom

Image DS311 for daily shoot project
The daily shoot assignment for today:

Communicate chaos, disorganization or messiness in a photograph. Find some beauty in it. (@divadeb88)

I don’t know why this one was so hard for me, and frankly I’m not totally crazy with my shot. That said, I did manage to approximate the image I had in my mind when I took it, which you can see below (thank you, Brian Lamb):
Image of maelstrom

If nothing else, these assignments start to pinpoint for me the elements of photography I would like to get a grasp on, like shutter speed, catching things in motion, dealing more intelligently with light, etc. But for the sake of time and sanity I will stick with this, unless my kids offer me a new vision of chaos when I get home tonight.

Posted in digital storytelling | Tagged , , | 5 Comments

Daily shoot: man in the mirror

Image for Daily Shoot 310 #ds310

Today’s assignment for Daily Shoot:

Use a mirror as part of a composition in a photograph today. Show yourself in the image if you’d like!

What can I say, I love the whole sideview mirror thing.

Posted in digital storytelling | Tagged , , | 12 Comments

Daily Shoot: A Softer 12 in Blue

Image of my cat 12 in Blue

Today’s Daily Shoot assignment:

Make a photograph of something that is soft, or at least looks that way. Convince the viewer of the softness.

This picture was fun not only because I get to feature my cat twelve’s so very soft throat, but also because with the onset of Fall in Virginia right now the light itself is becoming softer, and I love this time of year. So generative (that’s for you Tom Woodward), just like getting back in the habit of documenting my days visually has been this past week. So invigorating. And I haven’t even blogged about my crazy trip to the Natural Bridge yesterday. I uploaded over 1.5 gigs of images and video to Flickr last night, and I think I have some raw material for some pretty fun stuff.

Posted in digital storytelling | Tagged , , | 2 Comments

Daily Shoot: Pocket Kipple

Image of what was been in my pocket these last three days.

The Daily Shoot assignment for 2010/09/19:
Some carry a talisman, amulet, “lucky charm”, or just a comforting thing in our pocket. What do you carry? (@btusdin)

I love this prompt, and while my image is rather quotidian, I love the idea of what you carry in your pocket is a kind of space capsule of your life at any given moment. Plus it was quick and easy, just pour out my pockets and see what’s there, cause I am not organized enough to carry around any one thing for too long, save, of course cigarettes—and you’ll notice I still carry a vestige of that life 🙂

Posted in digital storytelling | Tagged , , | 11 Comments

DS106: An Internet Odyssey

Image of an illustration of Homer's The Odyssey

I’m teaching Digital Storytelling for the second time this semester, and we just finished week 4. The semester goes quick, and last time I didn’t blog this course nearly as much as I’d hoped to. So this semester I am trying to build the very assignments for the class into my blogging routine. A means to directly integrate the work I do here with the work I do in class, which makes total sense to me given the entire course is framed around the idea of one’s own space and the framing of a digital identity, both of which are part and parcel of an ongoing, fragmented narrative. It would be silly to try and divorce my work on the bava from the course. In fact, my work on the bava over the years is probably why I’m teaching a computer science course in the first place. My expertise is not in programming, and as an introductory, 100-level course this is very much about the web, and identity on the web as a form of narrative. The class is rooted in the web as a means of story telling, and like the web remains dependent upon everybody’s willingness to experiment, make mistakes, and participate regularly by bringing a sense of wonder and their own interests and visions to the fore on a regular basis and with their own voice.
Continue reading

Posted in digital identity, digital storytelling | Tagged | 6 Comments

Daily Shoot: When I get bigger

Image of Tommaso and I for Daily Shoot 307 (#ds307)

This photo credit goes to Antonella, who was thinking about this assignment with me most of the afternoon. I was feeling the pressure and really couldn’t think of anything too inspired. This prompt was hard for me given I spent most of the day doing yard work and being generally lazy. So I returned closer to home, and we took some shots of Tommaso. The one above captures the size better than the rest, and in many ways it is capturing the size of my babies when they are this small that started me blogging and taking photos and videos in the first place. A kind of blogging return home. Anyway, we wanted to play with the idea of objects within objects, like the matchbox car subsumed within our actual car, and use the side view mirror for interesting composition, but not sure that came out just right. Seems a bit forced, and not nearly as natural and real as Tommaso and me playing in the grass. So here is the image we were going for:

Image of side view mirror and car

Posted in digital storytelling | Tagged , , | 2 Comments

Daily Shoot: “In for the kill”

Image for #ds306

This is an image for Digital Storytelling 106, we’re doing the daily shoot assignments for the next week, and this is my choice for today, based on this assignment:

Showcase the beauty of living foliage! Make a photo of a single leaf or an entire “greenscape” today. (@DeForestRanger)

I have to say I’m liking the picture above (thanks to Joe Calpin for seeing the bumble bee) and I look forward to the next week of taking photos. I always wanted to do the photo-a-day for a year, but I’m not up to the whole year thing yet, but this represents my building up, and the assignments give me a frame. Also, I like the idea of immediately placing the ds106 internauts right in the flickr/twitter hashtag mix.

Posted in digital storytelling | Tagged , , , | 7 Comments