Changed index.py to test django

This commit is contained in:
Thomas FORGIONE 2015-04-18 17:22:36 +02:00
parent 50b41f49d2
commit 443f12f553
1 changed files with 14 additions and 3 deletions

View File

@ -1,7 +1,18 @@
#!/usr/bin/python
# -*- coding: utf-8 -*-
import sys
from webtools import Web
from django import template
from django.conf import settings
Web.render('index.html')
settings.configure()
t = template.Template(open('index.html','r').read())
c = template.Context({})
v = t.render(c)
print('Content-type: text/html')
print()
print(v)
# Web.render('index.html')