Commit 952ce97d8978073bb72e15f641e8cccf70887989

  • avatar
  • arvind
  • Wed May 29 19:13:52 IST 2013
Fixing API
swtr.py
(1 / 0)
  
6666 response.headers['Access-Control-Allow-Origin'] = '*'
6767 data = {}
6868 data_list = []
69 print request.form['data']
6970 for i in json.loads(request.form['data']):
7071 id = g.collection.insert(i)
7172 data['permalink'] = app.config['URL']+'/posts/'+str(ObjectId(id))
  
1515 {% endif %}
1616 <ul class=entries>
1717 {% for entry in entries %}
18 <li><a href={{ "/posts/"+entry.id }}><h2>{{ entry.title }}</h2></a>@<b>{{ entry.user }}</b>
19 {{ entry.text|safe }}
18 <li><a href={{ "/posts/"+entry.id }}><h2>{{ entry.title }}</h2></a>@<b>{{ entry.who }}</b>
19 {{ entry.what }} {{ entry.where }} {{ entry.how|safe }}
2020 {% else %}
2121 <li><em>Unbelievable. No entries here so far</em>
2222 {% endfor %}