modified template  a bit