Added extend_template()