refactoring using extends and include tags for more control