1 # -*- coding: utf-8 -*-
2 # This file is part of Wolnelektury, licensed under GNU Affero GPLv3 or later.
3 # Copyright © Fundacja Nowoczesna Polska. See NOTICE for more information.
5 from django.shortcuts import render_to_response, get_object_or_404
6 from django.template import RequestContext, Template
8 from infopages.models import InfoPage
11 def infopage(request, slug):
12 page = get_object_or_404(InfoPage, slug=slug)
13 rc = RequestContext(request)
14 left_column = Template(page.left_column).render(rc)
15 right_column = Template(page.right_column).render(rc)
17 return render_to_response('infopages/infopage.html', locals(),
18 context_instance=RequestContext(request))