Link to post Dominant Color in an image

Inspired by this great blog post by Manuel Wieser, I made a php script to find the dominant color in an image, and create a data-url containing a colored "spacer" gif. The hardest part was to figure out how the node.js "buffer" functions compare to php's "pack" function. For all the other cryptical stuff about…