From 443f12f5533ad447a3c36df06bf0ac53dd630422 Mon Sep 17 00:00:00 2001 From: Thomas FORGIONE Date: Sat, 18 Apr 2015 17:22:36 +0200 Subject: [PATCH] Changed index.py to test django --- index.py | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/index.py b/index.py index 7257e93..b15dba8 100755 --- a/index.py +++ b/index.py @@ -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')