You can use a variable to set the name of the template you are extending when using Django templates.