Hi, I'm Andrew Gioia, student at the University of Michigan law school and lead designer at Ingioi Design, a small web applications start-up in Pennslyvania. Check here for updates or click around for my professional and contact info. Thanks for dropping by.

News and Updates (all) RSS Feed

Jan. 4: Magpie RSS for Flickr.

I've been messing around (poorly) with RSS feeds for a while and last week I came across Magpie RSS, a super simple php class to handle pretty much any feed you can throw at it. Right now the Asides page uses Magpie for the Delicious bookmarks and Flickr photos; the bookmarks were pretty straightforward but I was having some trouble displaying the photos correctly. This is pretty rough, but if you're looking for some sample code to plug in here's what I'm currently using:

if ($url) { // Set $url to your Flickr url
    $rss = fetch_rss($url);
    $count = 0;
    foreach ($rss->items as $item) {
	if ($count == 14) { break; // to limit it
	} else {
	    $image = $item['description'];
	    $image_ary = explode("\n\n",$image);
	    $image_img = str_replace("_m.jpg", ".jpg", $image_ary[0]);
	    $image_img_ary = explode("</p>", $image_img);
	    $image = $image_img_ary[1];
	    $image = str_replace("<p>", "", $image);
	    $image = str_replace(".jpg", "_s.jpg", $image);
	    $image = preg_replace("/width="d+"/" , '', $image);
	    $image = preg_replace("/height="d+"/" , '', $image);
	    echo "$image";
} $count++; } }

You can set $url to your Flickr rss feed, and make sure to include the mapgpierss file ;) I'm pretty sure I'm adding some unnecessary steps in there, but it gets the job done. Feel free to test it out or email me if you've got something.

Dec. 28: New site design finally.

I finally found some free time over Christmas break to give this thing a much needed layout and brush up my neglected php skills. It's pretty trimmed down right now but I'm definitely still going to keep it bare bones this time. I also finally signed up for a del.icio.us account; I've been looking for a way to sync bookmarks across computers and I'm not sure why I waited so long on this, but it's definitely worth it. More coding!

Dec. 24: Merry Christmas!

First semester is finally over and I just got back from another great weekend in Grand Rapids :) Looking forward to Christmas with the fam.