I'm uploading a bunch of hi-res pictures to the gallery at the moment on a slow connection. Once that's complete I will get the code I've been using for a long time now, which I think is an SSI block I got from here.

////////////////////////////////////////////////////// SMF Gallery Random Picture - ver. 1.7.1 ////////////////////////////////////////////////////////// Developed by Thurnok// Thurnok -AT- tinyportal .DOT. net// November 30, 2006//// For list of all updates history, see the UPDATES.TXT attached file// in the post where you got this code, or the .ZIP file if you downloaded it//// Used in a TinyPortal phpblock or Article.// This block displays random picture(s) from// the SMF Gallery mod along with other information////////////////////////////////////////////////

// enable profile pics display?// 0 = disable, 1 = enable --- if enabled, and you are viewing a member profile, show pics from that member only// other options still apply (showtype, sort order, etc)$gal_profile = 1;

// only show pics from buddies?// 0 = disable, 1 = enable --- if enabled, will only show pics posted by members in your buddy list$gal_buddies = 0;

////////////////////////////////////////////////////// SMF Gallery Random Picture - ver. 1.8 ////////////////////////////////////////////////////////// Developed by Thurnok// Thurnok -AT- tinyportal .DOT. net// November 30, 2006//// Updated 9/26/2008// 1.8// - added display # of comments option//// Updated 10 April 2010 by Freddy888 to work with SMF2// Updated 12 July 2011 by Freddy888 to work with TP1// Used in a TinyPortal phpblock or Article.// This block displays random/most/least/newest/oldest picture(s) from// the SMF Gallery mod along with other information////////////////////////////////////////////////

// enable profile pics display?// 0 = disable, 1 = enable --- if enabled, and you are viewing a member profile, show pics from that member only// other options still apply (showtype, sort order, etc)$gal_profile = 1;

// only show pics from buddies?// 0 = disable, 1 = enable --- if enabled, will only show pics posted by members in your buddy list$gal_buddies = 0;