aboutsummaryrefslogtreecommitdiff
path: root/wqflask
diff options
context:
space:
mode:
authorPjotr Prins2016-10-07 10:49:03 +0000
committerPjotr Prins2016-10-07 10:49:03 +0000
commit3642a641c57621f2cbf87bed4657d58527d7b76f (patch)
treef43100a6c80f045f42ffaa42dfa37ae21fb479d6 /wqflask
parentea3f5cab2c43d267430c179581f6f2008c240b10 (diff)
downloadgenenetwork2-3642a641c57621f2cbf87bed4657d58527d7b76f.tar.gz
Tweets on main page are working
Diffstat (limited to 'wqflask')
-rwxr-xr-xwqflask/wqflask/templates/index_page_orig.html23
-rw-r--r--wqflask/wqflask/views.py4
2 files changed, 26 insertions, 1 deletions
diff --git a/wqflask/wqflask/templates/index_page_orig.html b/wqflask/wqflask/templates/index_page_orig.html
index 73d3e718..bc811ef6 100755
--- a/wqflask/wqflask/templates/index_page_orig.html
+++ b/wqflask/wqflask/templates/index_page_orig.html
@@ -221,7 +221,11 @@
<li><a href="http://genenetwork.helmholtz-hzi.de/">Germany at the HZI</a></li>
<li><a href="http://gn2.genenetwork.org/">Memphis at the U of M</a></li>
</ul>
- </section>
+
+ <div id="tweets"></div>
+
+
+ </section>
<!--<section id="getting-started">
<div class="page-header">
@@ -282,4 +286,21 @@
}
</script>
+ <script type="text/javascript" src="/twitter/js/twitterFetcher_min.js"></script>
+
+ <script type="text/javascript">
+ var configProfile = {
+ "profile": {"screenName": 'GeneNetwork2'},
+ "domId": 'tweets',
+ "maxTweets": 5,
+ "enableLinks": true,
+ "showUser": true,
+ "showTime": true,
+ "showImages": true,
+ "lang": 'en'
+ };
+ twitterFetcher.fetch(configProfile);
+ </script>
+
+
{% endblock %}
diff --git a/wqflask/wqflask/views.py b/wqflask/wqflask/views.py
index 33fab84d..a5b2870d 100644
--- a/wqflask/wqflask/views.py
+++ b/wqflask/wqflask/views.py
@@ -143,6 +143,10 @@ def tmp_page(img_path):
return render_template("show_image.html",
img_base64 = bytesarray )
+@app.route("/twitter/<path:filename>")
+def bd_files(filename):
+ bd_path = app.config['TWITTER_POST_FETCHER_JS_PATH']
+ return send_from_directory(bd_path, filename)
#@app.route("/data_sharing")
#def data_sharing_page():