modified template slightly