greycobra.com has a huge tut about building a template