changed to use templating structure in django