def get(self): self.response.headers['Content-Type'] = 'text/html' resources = Resource.getResources() resources = Resource.getResourcesFor6Through8(resources) values = { "title": "Middle School", "curr_url": self.request.url, } self.response.out.write(template.render('html/middle.html', values))
def post(self): lang = self.request.get("lang") resources = Resource.getResources() if lang: resources = Resource.getResourcesForSpanish(resources, True) resources = Resource.getResourcesFor6Through8(resources) values = { "title": "Middle School", "curr_url": self.request.url, "resources": resources } self.response.out.write(template.render('html/middle.html', values))