loop to write letters and pics to page