Commit a182289cd9c9e9b737ddc82a6b5129543136d11f

  • avatar
  • arvind
  • Wed Jul 10 17:34:19 IST 2013
Adding config.js to sweettext
  • Diff rendering mode:
  • inline
  • side by side

server.py

151 script = root.makeelement('script')151 script = root.makeelement('script')
152 script.set('src', url_for('static', filename='text-annotation.js'))152 script.set('src', url_for('static', filename='text-annotation.js'))
153153
154
155 config_script = root.makeelement('script')
156 config_script.set('src', url_for('static', filename='config.js'))
157
154 tree = root.makeelement('script')158 tree = root.makeelement('script')
155 tree.set('src', url_for('static', filename='tree.js'))159 tree.set('src', url_for('static', filename='tree.js'))
156160
192 root.head.append(us)192 root.head.append(us)
193 root.head.append(tree)193 root.head.append(tree)
194 root.head.append(script)194 root.head.append(script)
195 root.head.append(config_script)
195196
196 return lxml.html.tostring(root)197 return lxml.html.tostring(root)
197198

static/text-annotation.js

218 }218 }
219 };219 };
220})();220})();
221var config = {
222 'postTweetUrl':'http://localhost:5001',
223 'indexer':'http://localhost:5000'
224};