Why subscribe to the SDW newsletter?

  • Insight on business technology trends and news.
  • Case studies on ground-breaking innovation.
  • Invitations to SDW events and webinars.
  • Other worthy dispatches from our expert team.
  • No spam. Just cool stuff.


Please leave this field empty.

Go back to skookum.com

Blog

Where we talk about business tech,
hardcore development & craft beer

2 Comments

Nested content types on Drupal with Flexifield

I recently came across an excellent Drupal 6.x module called Flexifield.

Flexifield allows you to use an existing content type as a “template” for a custom field group on another content type. This makes it easy to nest content types and really improves usability when adding and editing nodes with references.

For example, if you wanted to have a content type called “book” which will have the ability to associate unlimited “book pages”. The old way would be use a node reference field that allows you to choose an already existing page in the system.

The Old Node Reference Way:

Step 1: Create the book page

Step 2: Edit the book and choose the book page to reference

Now this is all fine and dandy if you want your book page content type to be able to stand on its own, have it’s own url, be referenced by multiple books, etc.

But what if you know that each book page will be unique to it’s parent book? It will be pretty annoying to have to keep creating each page manually ahead of time so you can reference it. This is where Flexifield comes in to save the day. The module will allow you to create content “on the fly” within an existing content type, and still give you the ability to edit, delete and change ordering!

We simply enable flexifield, and choose it as the cck widget when we add the field for our book content type.

The Flexifield Way:

Pretty slick huh? Notice the “add another item” option at the bottom. This will allow us to add unlimited book pages on the fly, all from the main book edit page!

Some things to note:  When you add a book page with flexifield, this does not actually create a book page node, it just used the book page content type as a template to store the cck fields on our parent content type. All of the field information is stored directly in the parent book node object. The other thing to remember is that the book page content type is going to remain on the content creation screen, even though we do not use it directly. My suggestion is to hide it with some jquery so you do not end up confusing your content editors. I hope this post was helpful in getting you up and running with flexifield!


4 Comments

Tips on Moving WordPress to a New Server

Sometimes I wish WordPress was easier to migrate from a staging environment to the live site. There are tons of things hard-coded throughout the database with a URL that needs to be changed when you update a site’s url.

There’s the `siteurl` in the wp_options table, the `guid` colum in the wp_posts table, and then any images or internal links that may be in the body of a post or page with the CMS.

I’ve read plenty of deploy procedures, but I thing that I’ve gotten it down to a pretty easy process. Here’s how I do it:

  1. Pull down the entire structure from the staging server to your local machine (including themes and uploaded files).
  2. Pull a SQL dump of the staging database.
  3. Make sure the new server has a database and user set up – enter these into the wp-config.php file.
  4. Upload all the files to the new server, making sure that the /wp-content/uploads/ and /wp-content/uploads/*/ directories are writeable (for future file uploads).
  5. Upload the exact copy of the database to the new server.
  6. This is where the meat and potatoes are: Run this SQL command on the new server (obviously change ‘newdomain.com’ & ‘olddomain.com’ to suit your needs):

Hopefully this will help you when you go to move a WordPress site over to a new server. I wish it was easier too.


Leave a comment

Christmas Beer Update

The Skookum Christmas beer is almost done!

It finished fermenting over the past few days so I put it in the keg today. All that’s left is to chill is and then force-carbonate it!

I wound up using ale yeast instead of lager yeast, so this beer isn’t a true-to-style Doppelbock. Instead, I’m calling it “Skookum Christmas-Bock.” I guess the best name for it would actually be a German Altbier.

I hope everyone at the Christmas party will enjoy this very dark, very high ABV (~8.3%) beer I’ve made!

Transferring the beer from the fermentation vessel into the 5 gallon soda keg:

It’s sitting in my kegarator getting cold next to my current beer, a Coffee Stout:


Leave a comment

Software announcement: WP-Campfire

If you’re like us here at Skookum, you love the suite of apps from 37signals. Basecamp is an integral part of our project management and client communication processes. They’ve made all their products so easy to use and so complimentary to each other, I’m not sure how a client-based small business can function without them (or something similar).

One of their apps that we use a lot (probably second only to Basecamp) is Campfire: the group-collaboration product. It’s basically a glorified private IRC channel. Pretty much everyone in our company is signed into our Campfire main room all day long. We talk about ideas, post funny/geeky images & videos, and other general chit-chat.

We wanted an easy way for everyone to know when a new blog post was added to our website so everyone could go read and comment on the post. Out of this idea was born WP-Campfire.

WP-Campfire is a plugin for WordPress blogs that will use the Campfire API to post a notification to the chat room of your choosing when a new post is added. It has support for customizing the message that’s sent using variables like the article’s title, author “nicename”, post title, and link. The default behavior is to post a message in the form of: “New blog post by {author}: {title} – {link}”, but you can change it to whatever you want!

Here’s some screenshots so you can preview it without installing on your WordPress instance:

Main Configuration Page:

Post Edit Screen:

Check out the plugin and let us know what you think! (Please post support requests to the appropriate WordPress.org forum, not in the comments here.)

  • Installation instructions
  • Upcoming improvements
  • Undocumented quirk: you should probably create a “dummy user” and use that API string to post the messages. The API will likely boot you from the room if you’re in the room and WP-Campfire attempts to post a message as you.

Rest-assured: this post was posted to our Campfire chat room the moment I hit the “publish” button.


Leave a comment

Web Development & Beer – They Go Hand-in-Hand.

At Skookum, we like to write some serious code… but we also like to let loose once in a while (OK, maybe more than once in a while). When I was approached to make a special beer for our company Christmas party this year, I jumped at the chance!

I’ve been a pretty serious homebrewer for almost 2 years now. I’ve got plenty of batches under my belt and I just recently started putting my homebrew into 5 gallon soda kegs.

I decided on a few different styles I would enjoy making and then put it to a vote. Here were the choices:

  1. Nut Brown Ale
  2. Amber Ale
  3. Honey Amber Ale
  4. California Common
  5. Irish Red Ale
  6. Doppelbock

After a few days of deliberation, the Amber Ale had almost won. Then Justin pointed out that-of all the choices-the Doppelbock had the highest ABV. For some reason, after that comment, people started changing their votes! In the end, the Doppelbock won.

So after work I headed down to Alternative Beverage and got the materials I needed to brew this beer. After entering all the ingredients into my brewing software, we were looking at about 8.3% ABV on this one – pretty dead on the target where I was shooting for.

I think I’ll be pleased with how this beer turns out. This is my first attempt at making a Doppelbock, so everyone at the party will be guinea pigs for this batch!

I took some photos and video of my brewday.

It’s amazing how scientific and precise beer making is, while at the same time allowing for interpretation and creativity. Those are some of the main reasons I enjoy it as a hobby.

If you’d like to learn more about homebrewing, I’d highly recommend basicbrewing.com as a place to start, but there are so many resources out there on the web. You can get started with a minimal investment in equipment and ingredients and you can brew some great beer (sometimes better than commercial store-bought beers I’ve had) with a little time, patience, and know-how.

This post was not meant as an overview of homebrewing, but if you have questions, I’ll gladly answer them for you (if I can) in the comments, or point you in the right direction for an online resource.


1 Comments

Google’s Instant Preview: Insanely Amazing

Google introduced a new search feature the other day called “Instant Preview“, where when you hover over the url of the site, you get an image of what the site looks like. This tech has been around for a while and when in found the context of a site where you are trying to read an article is, frankly, annoying. Google’s implementation is fantastic – and because you’re not trying to read Google Search, the site previews are a welcome addition to the search results page.

But I think that how they are actually serving the data to your browser is even more fantastic than the front-end experience when you look at some of the details behind how it’s done.

The developers put up a post on the Google Code blog about how they strive to keep the pages loading fast as well as how they implemented lots of compression and caching mechanisms:

…you will have noticed that we send back the image data as sets of data URIs. Data URIs are base64 encodings of image data, that modern browsers (IE8+, Chrome, Safari, Firefox, Opera, etc) can use to display images, instead of loading them from a server as usual.

To show previews, we need the image, and the relevant content of the page for the particular query, with bounding boxes that we draw on top of the image to show where that content appears on the page. If we used static images, we’d need to make one request for the content and one request for the image; using JSONP with data URIs, we make just one request. Data URIs are limited to 32K on IE8, so we send “slices” that are all under that limit, and then use Javascript to generate the necessary image tags to display them. And even though base64 encoding adds about 33% to the size of the image, our tests showed that gzip-compressed data URIs are comparable in size to the original JPEGs.

In my experience, some of the preview images are a little lacking in quality – the jpeg compression seems pretty high on some sites. Looking at the preview image for our blog page, the JPEG compression on the downloaded image is at 54% – that’s pretty far below the standard that generates “good quality” JPEG images.

Hopefully Google will continue to refine this feature and make it even better.

Color me impressed!

[via HighScalability.com]


Page 15 of 18« First...10...1314151617...Last »