Friday, June 22, 2007

Mastering PHP's XML Parser

Probably not the most exciting subject for anyone else, but I've spent a lot of hours in the last couple days writing a script to automatically read ATOM feeds into a webpage. And yes, I'm aware that such things already exist, and can be found easily on Sourceforge, but doing it myself helped get me that much deeper into working with PHP, and made sure that I understood both the ATOM schema and PHP's XML Parser.

The XML Parser requires several functions to be put into it in order to do whatever it is you want it to do. You need a function to deal with start tags, one for end tags, and one for character data between those tags. The only place you can deal with attributes is within the start tag function. It helps, then, to have some global variables to store the information you desire to pluck out of an XML document. This sounded like something suited for an object-oriented approach, so I started by building a class called ATOMParser. I made the start, end and character functions internal, and created two public functions, one to parse a document, the other to set how many results to return and which label to search for.

Here entered a wrinkle; on my server, where I did much of my testing, I run PHP 4.something, whereas the university server has PHP 5.something. PHP 5 has a whole bunch of reserved words like public, private and interface, whereas PHP 4 does not. To make things work on both ends, I had to go generic with my terms. It all worked fine, but theoretically, someone could call the start or end functions from outside the ATOMParser object... for what little good it would do.

Another difference: on my server, I could simple open the XML straight away, whereas on the URI server it was necessary to stream the document in chunks, then open it. What does this mean? Well, using code that worked on my server to display all the different posts in the blog only showed the latest post (maybe the latest two, if I refreshed just right) on the URI server. The packeting fixed that.

So, my end result is a pretty portable piece of PHP that I can use elsewhere on the GSLIS site. You can see its current implementation at More will follow, notably the joblist. I will also likely use this somewhere in my website for bringing in blog info (same blog package as GSLIS). For other XML documents, I can now create custom parsers to do my bidding. Very exciting.

Well, to me, at least.

Thursday, June 07, 2007

SLA 2007 - Wrapup

SLA 2007 has come and gone, and I am certainly the better for it. I just wanted to take a moment and review my total experience here in Denver.

Technical skills:
I am now more than proficient with wikis and podcasts. Not only to I know a fair amount about setting them up, but I also have ideas on what kind of content to use with them. I'm more confident with my abilities, both at the IT level, and the CS level. Once again, everyone I talk to about my dual degrees says I'm going to have my pick of jobs.

I've picked up some new hints on great tools to use in the next year. Google Custom Search Engine will get used as soon as I'm back at work for the GSLIS. Until I can get MediaWiki installed on my server, Sarah and I might use PBwiki for planning our wedding. The screen-to-flash tutorial creator Wink I think might already be handy for a colleague, and I hope for me soon, as well. Just talking to folks, I got turned on to a Firefox extention that lets me to browser screen captures quickly and easily. And, I can't forget all the wonderful Web 2.0 search tools presented by Mary Ellen Bates.

I've always cared about the environment, but Al Gore's speech was that much more energizing to really do something about it. The free pedometer's from Thompson and the Social Science Division added that much more encouragement to use my own leg power to get around.

I'm also more caught up on the latest issues surrounding copyright and collaboration. I have a better idea what I need to do when I do any kind of digitization. I'm also more educated on Creative Commons, and how to utilize it for better information dissemination.

I have met so many wonderful people here, I doubt I could list them all even if I had my stack of recieved business cards in front of me. I can group them into several large groups, and thank them that way for their contribution to my conference experience.
  • Rhode Island chapter (namely Bill Anger and Jane Loescher)
  • Boston chapter (particularly Dave Ware, who has been phenomenal to me this whole conference)
  • Kentucky chapter (Leoma, James, Stacey, Alex, Valerie, Liz, and all the rest. They were incredibly nice to me, and let me crash their dinner and drinks time last night)
  • IT Division (which has quite the overlap with the above mentioned chapters)
  • The SLA Bloggers (you're all going into my reader!)
  • The vendors and instructors from all the myriad companies who sponsored SLA 2007
  • All the wonderful folks I've met in classes, at parties and in passing.
Please don't feel left out if I didn't mention you specifically, since I'm kind of pressed for time here in this coffee shop, and don't have all my info in front of me.

Division Service:
Hanging out with the IT division has led me to fall into the position of possibly being Chair Elect of something this coming year. Since this is one of the things I mentioned specifically in my stipend-winning essay that I'd like to do, I feel that much more successful about my journey out here.

What I'll do differently in Seattle:
  • Bring business cards. I should actually have an official affiliation by then, so this should be easy enough to do.
  • Not be moving the same week as the conference. This is stressful for everyone.
  • Bring a PDA or smaller laptop. This old Inspiron is a shoulder-killer.
  • Sign up as an SLA Blogger. Official access to the press room would be really nice.
  • Plan more relax time. I ran my self pretty ragged this conference, and while I got a lot out of doing it, I think I'd prefer to take some more evenings off (at least partially) next time.
  • Attend with Sarah! I'm really hoping she'll decide SLA is right for her, and that she'll be able to get away for the conference dates. Her presence would make the conference truly perfect.

Well, time to wrap this up, and start moving towards the airport.

Wednesday, June 06, 2007

SLA 2007 - Day 4 (Wednesday)

We start off with our closing speaker, Scott Adams, creator of Dilbert. Very good presenter, intelligent, humourous (very well timed), and all in all just plain delightful. Other SLA members have reviewed Scott's presentation. Click here or here for more in-depth opinions.

New Technologies in Instruction and Training Poster Session
I stopped by this briefly, and picked up several really good tips, tools and ideas. Below are what I found to be the gems.
  • Drexel University Libraries have created a "subway map" of the many avenues of getting users content. The "stations" on the different "lines" show how complex the information delivery world is. They have even created "schedules" for various "routes" (LC schedules). Its all quite innovative.
  • A tool called Wink allows you to do screen captures, or import from image, then add audio, explanation boxes, buttons, etc. and export to Macromedia Flash (.swf). Sounds like a wonderful way to create cross-platform tutorials for various programs your library or institution might be using.
  • Tim Tierney at URI was talking about these pens can digitally read what you write on paper. Well, I ran across that tool in this session. Its called Tegrity.
  • I got a name of someone at Yale libraries that's doing podcasting. Since I'm moving a few blocks away from Yale, and my upstairs neighbour-to-be is a librarian there, I figured this was a good connection to try to make.

Podcasting the Librarian Way
by the IT division, with speakers Tammy Allgood and Debbie MacLeod
This course provided an introduction to some of the possibilities of what podcasting can do for a library or information center. Tammy Allgood, of Arizona State University, showed us what she was able to do at her library for less than $300 of equipment. Debbie MacLeod, of the Colorado Talking Book Library, presented some of what her institution was doing to bring literary content to the textually impaired. Below are a list of podcasts that librarians have put together.

SLA Tech Zone: Podcasting – Make Noise the New Fashioned Way
presented by Thomas Dopko of Dow Jones
Another wonderful presentation by Tom. This course covered the technical requirements for getting a podcast up and running. That is, what do you have to do to be a podcaster. I won't go to far in depth, since you can view the slides of the presentation until Dec 31. I will, however, summarize how incredibly easy it is to podcast. You need the following:
  1. Content - find something you want to say, either in audio or video form
  2. Record that content in a standard form - .mp3 for audio, .mov for video
  3. Host the content - put it on a server
  4. Get or make an RSS feed for that content - you can use a free service like Switchpod, or write your own XML feed
  5. Share your feed address with people - let them know where they can find your content
  6. As a user, have a feed reader for podcasts (iTunes works well, so does Juice), and put that address into it.
  7. YOU'RE DONE!!!!
I'm looking forward to creating and hosting some of my own podcasts soon. I already have the tools, the software, and server to get everything up and running. I would just need to upload the videos and mp3s to the Apache part of the server, write an RSS feed document, and then point people to it all. Couldn't be easier.

Tuesday, June 05, 2007

SLA 2007 - Day 3 (Tuesday)

More courses today. Fortunately, several of them appear on other blogs, so I can save some typing time.

SLA Hot Topic - Collaboration vs. Copy Protection
A panel discussion with prominent folks from several areas in the copyright battle. This session looked to present all the possible viewpoints for what can be done with copy protection in the 21st century.

First was Stephen Abrams, who brought up the inconsistency of treating creative works the same as scholarly works. Do authors really make continued discoveries 70 years after their deaths?

Next, moderator Victor Camlek talked about the need for continued copy protection in order not to disrupt the current business model. Users and publishers can sometime come into contention, and something needs to be worked out to keep information flowing, while still "following the money"

Bill Burger from Copyright Clearance Center talked about the difference between the desire for financial protection, and the need for recognition. Different kinds of writers have different goals, and CCC has several products out there now that help users figure out exactly what permissions they have with a specific piece of material. The goal of CCC is to make it easy to do the right thing.

Crystal Megaridis of Praxair Inc talked about her company, and its need for both correct and complete content. These can be at odds, since one can't necessarily trust things that come from outside one's institution. Yet, that is where most information exists.

Finally, Thinh Nguyen of Science Commons spoke of a parallel world where the "amber of copyright was softened", and science was able to lead to cures and discoveries that many years sooner. The cost we face in living in the world we do is invisible to us, since we cannot see what might have happened. By using the semantic web, he hopes we can loose the facts from publications, distributing them as quickly as technology allows, while still providing protection for the creative part of the work.

In the Q & A, some asked if Fair Use was dead. No, definitely not. Google, for one, is banking on it with its digitization efforts. Nguyen quipped that Fair Use was a 'license to hire a lawyer'. Its a primarily American concept, Abrams points out, and that's why the music genome service Pandora is only available in the US.

Is there hope? Of course. By working with publishers and copyright holders, and by using new protection measures like Creative Commons, we have the potential for keeping the vital information flowing, while still protecting the economic investment of those involved in creating a work. As Abrams pointed out, copyright isn't a restriction; its just a need to ask permission. Often times, you'll get it.

20 + Tips for Searching the NEW Web
presented by Mary Ellen Bates
Thankfully, J of J's Scratchpad already did this one for me. You can read it here. I highly recommend that you do.

SLA Bloggers get-together at the Rialto Cafe
A wonderful chance for me to get to meet some of the people I'm subscribed to, as well as help figure out how to provide even better conference coverage next year. This should be appearing on the SLA blog shortly, and I'll edit the post to link into that once it comes up.

EDIT on 5-6-07: Here is the link to the post on the SLA Blog. Good photos for all the years. I hope to show my smiling face in this pic-series from now on.

Oh, man, am I tired. I think once INFO-EXPO wraps up, I'm going to call it an evening (until the Gold Digger's Ball). I could use a little feet-up time. Perhaps dinner with a high-school friend of mine who's in the area...

SLA 2007 - Google

Now that I've had some rest (not enough, surely), and I have a little time before my conference day begins, I can do my post on Google at SLA.

Honestly, I'm a little disappointed. Google's presence here is remarkably minimal. They don't have much information at their booth, just some tips for using some of their latest products. I think that Google, a first-time exhibitor at SLA, is trying to get synchronized with the librarian community, feeling us out while we do the same to them. This results in lots of really basic material being presented. We got to hear about Custom Search Engine, which I will put into practice on the URI GSLIS site when I get home. The rest, the tips and tricks, Book Search, Patent Search and News Archive, were presented as an overview only. I was more curious about new programs, things that have yet to launch, but Google won't speak to any of these things (as an aside, yesterday afternoon they just launched a new Trends feature in Google Reader, which gives you stats on what you've read, from whom, and what you did with those posts).

When discussing Book Search, I asked if they kept the Subject Headings from records of the books they digitized. Rather than a yes or no, the young lady said they kept everything in the libraries original records. Presumably this includes Subject Headings.

As noted in an SLA Blog post, no, Google does not have a library. ::jeer:: But they do have fortune cookies, which are quiet delicious.

  • Blue: Blueberry - "Tip: use the search box like a calculator What to type: 4+7, 30% of 55, 20^2 or 13cm in feet What you'll get: the answer"
  • Red: Strawberry - "Tip: exclude results you don't want What to type: bass -fishing What you'll get: results for bass the musical instrument, not the fish"
  • Yellow: Lemon - "Tip: get the weather forecast instantly on your cell phone Send 'weather 90210' to 446453 (Google) What you'll get: the weather forecast for 90210"
  • Green: Mint - same tip as Blue

Monday, June 04, 2007

SLA 2007 - Day 2 (Monday)

Man, am I beat! I got a late start today, but still, I spent so much time running from event to event this afternoon, evening and night, I'm about ready to ZZZZ out right here in the hotel lobby. I will attempt to blog first.

INFO-EXPO (Round 2)
I took a second spin around the expo floor, gathered some more swag, talked to some more vendors (got a few ideas and resources for the thesis), got my passport stamped, ran into someone I met last year at the Newbies meeting, and picked up an invite to the Thompson party.

Google Presents Tales, Tips and Tricks for Librarians
As I write this section, I realize that its just too huge an information dump for me to handle writing tonight, in a single post. I will defer this until later. Until then, you can read Emma Wood's post on the SLA Blog.

Tour of Flying Dog brewery
As I discovered in my CE class on Sunday, Flying Dog brewery offers tours at 4PM on weekdays. This directly conflicted with the SLA presentation Science of Beer, but I think I made a good choice; still tons of beer information, as well as some on the whiskey company next door, and samples for all! I went with Jeannie Bail, the Library Director at Allen & Company LLC, who was in my wikis course. I got to try two Belgian whites, a Barley Wine, and some fine Colorado whiskey. Despite the long walk and being a little late, it was definitely a great time!

Oh, and Flying Dog does have its own Beer Library.

Its neighbour, Stranahan’s Colorado Whiskey, has this lovely, custom made copper still. Just had to take a photo.

Thompson Party, SLA Boston dinner and IT Division Science Fiction Writers night
All of these were done in whirlwind succession. The Thompson party was at the Natural History Museum, so I got to eat absolutely delicious food while surrounded by wildlife dioramas. I had to leave very, very quickly to get to the SLA Boston dinner, which left from the Hyatt and went to Tamayo on 14th and Lawrence. Good food, good company. After that, I walked over to the IT Divisions event event. I tried to put in as best a presence as I could, but I was so tired, I had to call it a night.

That essentially brings us to now. Overall, I seem to be losing a lot of things today: my pedometer (got it replaced, and I've almost made up the 6 miles on the old one), my hotel room key (must have dropped it taking out my wallet somewhere...), and my internet connection (I'm just not having tech luck this trip). Hopefully I won't be losing sleep tonight; another long day tomorrow, as well as doing that delayed Google post.

SLA 2007 - Day 1 (the rest of the day)

My first full day at SLA 2007 was packed to the gills. I've already mentioned the amazing 4 hour CE course on wikis. This post is dedicated to the rest of the day.

Before all of this, I grabbed my pedometer. I plan on walking a lot, so why not have the chance to cash in on it? Plus, its a nifty little gadget for back home.

It was necessary to procure sustainance after such a long stretch of learning, so I hit up the 16th St. Mall, and stopped in at Marlowe's (16th and Glenarm). Delightful service (my waiter's name was Adam), and wonderful beer (a local brewery produces an exclusive line, the Big Nose series, for Marlowe's; try the wheat beer!). They specialize in seafood and beef, and do it very well. I hope to go back.

I headed back to the INFO-EXPO after lunch. I cruised the whole place, talking to a lot of vendors and picking up free stuff. I learned a lot about the current state of library technology, publications and services. Had I a copy of An Inconvenient Truth, I probably still wouldn't have waited in the Al Gore book signing line (it was very, very, very long, but I hear it was pretty quick). Ran into Bill Anger, Jane Loescher, Tony Stankus and Lee Peterson from SLA:RI.

Al Gore:
Several of my colleagues have already blogged about Mr. Gore's speech, so I won't repeat too much. It was awesome. Very passionate. And while it would be nice to have such a great guy in the White House, I do agree that he will much more effective as a 'rock star' raising the public awareness. Keep the pressure on, Mr. Gore! If applause are any indication, SLA is behind you.

Some links to issues loosely related to content in the speech, as I found THIS VERY MINUTE on Slashdot:

This is the point in time when I posted my last blog... So much lag. I miss my PDA!

IT Division's Welcome to Denver Open House (Analog Game night):
Man, do IT librarians know how to party! This event was amazing, with lots of fun card and board games, good food, an open bar and lots of good ol'fashioned networking. I finally got to meet Dave Ware, the fellow from SLA Boston who's been helping me set up the finances to come here to Denver. I also got to meet Jill Hurst-Wahl and Tracy Z. Maleeff (Library Sherpa), as well as see Thomas Dopko from Dow-Jones again (he taught some of my Tech Zone courses last year). I watched a group of librarians from the University of Virginia play cribbage (I chipped in my expertise as needed). I eventually wound up playing Texas Hold'em with Tracy, Dave, and a strong contingent of librarians from Kentucky. I took a class on poker back in my undergrad, but I never seem to get enough practice to get really good. Oddly enough, in the last hand of the evening, when everyone went all in, I won the pot (with something piddly like a Queen high). The pot came with a martini shaker, and there is a photo out there somewhere... I must track it down.

I tried to catch up on my sleep last night, and now, with a venti mocha and an apple fritter in my system, I'm ready to tackle the conference once more. Today, I look forward to Google's Tips and Tricks presentation, a tour of Flying Dog brewery, dinner with SLA Boston, and another wonderful IT Division evening.

Sunday, June 03, 2007

SLA 2007 - Day 1 (Sunday) - CE Course

8:00 - 12:00 : CLICK U LIVE! Organizing your content and collaborating on the web
By Karen Huffman and Cassandra Shieh

This CE workshop focused on how to use wikis to enhance your information collaboration project. We started out with a brief introduction, where everyone stated their names, organizations and favourite places to travel. We then dove immediately into an overview of what wikis are, what they do well, and several examples of prominent wikis, both engines and implementations.

So, why use a wiki? If you have a situation where you have multiple people developing some kind of informational project, be it a manual, a reference material or an event planner, and you'd like to avoid multiple versions of documents being emailed back and forth and back and forth, a wiki is for you. It essentially lets you bring everyone into a common workspace, tracking changes and letting you connect pieces of information dynamically.

How is it different from a blog? Blogs are a single voice, even if they are made up of multiple contributors. That voice is presented chronologically, in weekly, daily, hourly or minutely posts. A wiki, however, is not chronological. True, one can track the changes made over time, but a wiki has a far more complex structure. Its pages, rather than being broken down by units of time, are broken down by units of content. Both tools have their place, and can easily be made to work together.

Can't anybody edit a wiki, thus calling the information therein into question? This is the case only if you want it to be. You can choose, on most wiki engines, what level of permission each kind of user has. The casual web browser can be a read-only viewer, and editors can be assigned by your department. You decide who gets what rights to do what when you set up the wiki. You can make it a free public utility like Wikipedia, or put it on your intranet. Its all up to you.

After the overview, we talked a little about 5 major wiki engines:
  • Confluence - This is properitary software, with a price-tag. This is the wiki package SLA bought.
  • MediaWiki - The software behind Wikipedia. This is what we learned the most about.
  • PBwiki - a hosted solution that quick and easy
  • Socialtext
  • Wetpaint - free, hosted, but ad-supported, and with no user permissions
  • Other can be found and compared at Wiki Matrix

We dove into MediaWiki, working in a sandbox created by Karen (who won a well-deserved SLA award later in the day, btw). This hands on experience was ABSOLUTELY WONDERFUL, and exactly what I needed from this course. We created our own pages, used templates to save on repeating content, added extensions, uploaded media files, created tables of contents, and much more. I'd give you the example URL, but its password protected right now. When I get the new disk image for the SquareOne, which will hopefully support MediaWiki, I'm installing it post haste.

We intended to go into Wetpaint next, but ran out of time. I will hopefully have a chance to play with it in the near future.

This has to be the most useful course I've ever taken. Thank you, Karen and Cassandra for a wonderful session. I look forward to using wikis in my future projects (I'm already thinking PBwiki for organizing my wedding).

Saturday, June 02, 2007

Arrival in Denver

After a lot of flying and bus riding, I made it to the hotel in Denver. Nice place. The 16th St. Mall has lots of interesting shops, and free public wifi, which I'll get into in just a moment.

I've been craving a free internet connection since PVD, so that I can configure my laptop to make my time here at the conference easier. Here's what I need to do:
  1. Upgrade Firefox to 2.0.x
  2. Install the necessary extensions
    • FireFTP (to access my server)
    • Twitbin (to keep on a Twitterin')
    • Zotero (an absolutely amazing bibliographic management tool. I could rant. I might later).
  3. Configure my quick bookmarks bar:
    • Conference Wiki
    • All my Google apps, like Gmail, Reader and Blogger
    • Homepage for my Digital Libraries class (I did some reading summaries on the plane)
  4. Make iGoogle my homepage (so I can get a quick snapshot of what's going on)
I'd have done this upon arrival to the hotel, but my computer doesn't seem to have a working Ethernet port anymore. And wifi doesn't get up to my floor. So, here I sit in one of the bars on the street level, typing away, wishing I could be doing it at a desk in my room. This laptop is wicked heavy! Oh, well, we do what we must. It's not like I won't be otherwise incredibly busy starting tomorrow.

Oh, and since I was bumped to a different hotel because of construction, my credit card payment information has been lost in the struggle. This means a $700 hold on my debit card until we can get things squared away financially. I know SLA Boston will make everything work out alright, but I am moving right after I get home, and there is still that pesky lease to sign....

And as an aside, who should be riding the same bus as me to the same hotel, but Tony Stankus! This harkens back to last year, when I thought, "Gee, I wish I'd run into Tony", and BAM! there he walked by. With any luck we can get together for a drink or a meal, but we're both running around like crazy this year. At least I got to see him.

Blog title change

I've never been very good with titles. I've always liked working in the math and science realm, because when you wrote a paper, all you had to do was describe all its key points in the title, and you were set. Coming up with catchy titles, like one must in the arts, social sciences and humanities, is just not a talent of mine. So, I enlisted the help of my wife-to-be, Sarah, to help me come up with a better blog title. You'll notice it above.

In other news, I got an email back from Quad Microworks, and they will be offering a downloadable disk image with the "highest version numbers that the original hardware can handle without slowing down too much" of APM for the 1st gen system. It should be out after the 2nd gen systems ship.

Friday, June 01, 2007

It figures...

Before I can even get the thing fully up and running, they go and release a second generation device...

I doubt they'll have a trade-in program... and after the hassle of moving so many gigabytes of info onto the current system, I'm not sure the doubled CPU and RAM would make up for it. With any luck, they'll provide us first-gen'ers a way to upgrade our MySQL and PHP versions. I've asked.

Getting ready for SLA 2007

I'm currently printing out some articles for my Digital Libraries class, so that I might have productive things to read on the flight to Denver. Unfortunately, many of these documents were born digital, and it sucks up a lot of paper to print them (one of the assigned readings is actually a book, only 47 pages, but still). I'd plan to do other work on the plane, but my laptop is now completely battery-dead, and they don't typically provide wall sockets on a 777. I suppose I could bring a book and ::gasp:: relax a little...

Since my PDA was thoroughly destroyed last winter, and my phone's internet connection is both slow and expensive, I'm also going to make a printed packet of relevant information about my stay in Denver, including a map and calendar. Not nearly as high-tech as I'd like, but I'm pressed for time.

Oh, and I finally figured out why the Dynamic DNS services I'd tried for the SquareOne haven't worked; its my ISP. Cox blocks port 80 incoming, so you can't run any kind of web server. They do not block Telnet or FTP access, so I will be least be able to access my files remotely, but that's why the website hasn't migrated yet. Once we move, we will change ISP to one that doesn't explicitly block port 80. So long as I don't use my site for commercial purposes, I should be fine within this other ISP's service agreement.

Interesting note on ISPs: You aren't allowed to use any kind of Linux with their services. Not that there is any technical reason why you couldn't (the SquareOne runs Linux, and here I type), but they just don't want to train their people to deal with it. Not that the support people I've encountered when calling an ISP seem trained at all, but that's one of those rants I shall save for a different blog.