SEESenv/web/hgbook/comments/views.py
changeset 3 6cee07c589cb
parent 2 52d12eb31c30
child 6 1ce9b33fb6ff
equal deleted inserted replaced
2:52d12eb31c30 3:6cee07c589cb
     8 from django.template.loader import get_template
     8 from django.template.loader import get_template
     9 from django.utils.simplejson import dumps 
     9 from django.utils.simplejson import dumps 
    10 from p_list import *
    10 from p_list import *
    11 from BeautifulSoup import BeautifulSoup
    11 from BeautifulSoup import BeautifulSoup
    12 import glob
    12 import glob
    13 html_folder='/home/amit/SEES-hacks/web/html/'
    13 html_folder='/home/hg/repos/SEES-hacks/SEESenv/web/html/'
    14 
    14 
    15 def sort_dict(dict):
    15 def sort_dict(dict):
    16 	new_dict = {}
    16 	new_dict = {}
    17 	sorted_keys = dict.keys()
    17 	sorted_keys = dict.keys()
    18 	sorted_keys.sort()
    18 	sorted_keys.sort()
    47 	print request
    47 	print request
    48 
    48 
    49 
    49 
    50 def index(request):
    50 def index(request):
    51 	html_files = glob.glob(html_folder+'ch*.html')
    51 	html_files = glob.glob(html_folder+'ch*.html')
    52 	print >> sys.stderr ,html_files	
    52 #	print >> sys.stderr ,html_files	
    53 	print >> sys.stderr ,"just checking whether i got here"	
    53 #	print >> sys.stderr ,"just checking whether i got here"	
    54 	print >> sys.stderr , html_files	
    54 #	print >> sys.stderr , html_files	
    55 	html_files.sort()
    55 	html_files.sort()
    56 	link_list=['/review/html/'+a.split('/')[-1] for a in html_files]
    56 	link_list=['/review/html/'+a.split('/')[-1] for a in html_files]
    57 #	print >> sys.stderr , html_files        
    57 #	print >> sys.stderr , html_files        
    58 	title_list=[]
    58 	title_list=[]
    59 	for html_file in html_files:
    59 	for html_file in html_files: