[Gilles Lenfant] > jf = open('myimage.jpg', 'rb') > binaryJPGbuffer = jf.read() > jf.close() Or even more cleanly (in C Python): binaryJPGbuffer = open('myimage.jpg', 'rb').read() which does the same. You even spare `jf', and a few nanoseconds :-). -- François Pinard http://www.iro.umontreal.ca/~pinard