Some of the code from my website www.istorical.com