about summary refs log tree commit diff
path: root/templates
diff options
context:
space:
mode:
authorHao Chen2019-05-09 00:07:32 -0500
committerHao Chen2019-05-09 00:07:32 -0500
commit888e95f82ec96129257ff9064e9860a275fb7b15 (patch)
tree607903cb4711517101c86e9119a8419b14a4c7d9 /templates
parent502008d20887f69557e223129e2f520d51272c2a (diff)
downloadgenecup-888e95f82ec96129257ff9064e9860a275fb7b15.tar.gz
clean up
Diffstat (limited to 'templates')
-rw-r--r--templates/cytoscape.html3
-rw-r--r--templates/index.html20
-rw-r--r--templates/layout.html6
3 files changed, 23 insertions, 6 deletions
diff --git a/templates/cytoscape.html b/templates/cytoscape.html
index 749b042..fd2000e 100644
--- a/templates/cytoscape.html
+++ b/templates/cytoscape.html
@@ -1,7 +1,8 @@
 {% extends "layout.html" %}
 {% block content %}
 
-<script type="text/javascript" src="{{ url_for('static', filename='cytoscape.min.js') }}"></script>
+<script src="https://cdnjs.cloudflare.com/ajax/libs/cytoscape/3.6.0/cytoscape.min.js" integrity="sha256-uZV2wRlscgr52q3Wb3Oew0rKCPsM3g4aBTv46sF4qzg=" crossorigin="anonymous"></script>
+
 	<div id="cy"></div>
 	<script>
 		var cy = cytoscape({
diff --git a/templates/index.html b/templates/index.html
index 27455fb..ba18e0c 100644
--- a/templates/index.html
+++ b/templates/index.html
@@ -2,10 +2,26 @@
 {% block content %}
 <p>
 
-    <form class="form-inline my-2 my-lg-0" action="/search">
-      <input name="query" class="form-control mr-sm-2" type="search" placeholder="Rgma Nrxn3" aria-label="search" value="Rgma Nrxn3">
+    <form action="/search">
+      <input name="query" class="form-control form-control-lg" type="search" placeholder="e.g., Rgma Nrxn3, up to 5 terms are allowed" aria-label="search" value="">
       <button class="btn btn-outline-success my-2 my-sm-0" type="submit">Search</button>
     </form>
+	<br>
+	This app searches PubMed to find <u>sentences</u> that contain the query terms (e.g., gene symbols) and  a drug addiction related keyword.  <a href="https://github.com/chen42/RatsPub/blob/master/ratspub.py#L95-L129">These keywords</a> belong to the following categories:  
+<ul>
+<li> names of abused drugs, e.g., opioids</li>
+<li> terms describing addiction, e.g., relapse </li>
+<li> key brain regions implicated in addiction, e.g., ventral striatum </li>
+<li> neurotrasmission, e.g., dopaminergic </li>
+<li> synaptic plasticity, e.g., long term potentiation </li> 
+<li> intracellular signaling, e.g., phosphorylation </li>
+</ul>
+
+<br> 
+Live searches are conducted through PubMed to get relevant PMIDs, which are then used to retrieve the abstracts from a <a href="https://dataguide.nlm.nih.gov/edirect/archive.html">local archive</a>. The relationships are presented as an interactive <a href="https://js.cytoscape.org" >cytoscape</a> graph. The nodes can be moved around to better reveal the connections.  Clicking on the links will bring up the corresponding sentences in a new browser window. 
+<p>
+<hr>
+<a href="https://github.com/chen42/ratspub"> Source code </a>
 
 {% endblock %}
 
diff --git a/templates/layout.html b/templates/layout.html
index 0d3021e..d64b331 100644
--- a/templates/layout.html
+++ b/templates/layout.html
@@ -9,14 +9,13 @@
     <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css" integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T" crossorigin="anonymous">
 	<link rel=stylesheet type=text/css href="{{ url_for('static', filename='style.css') }}">
 
-
 	<title>RatsPub: Relationship with Addiction Through Searches of PubMed</title>
 </head>
 <body>
 
-<nav class="navbar navbar-expand-lg navbar-light bg-light">
+	<nav class="navbar navbar-expand-lg navbar-light bg-light">
 	<a class="navbar-brand" href="/">RatsPub:</br> <span style="font-size:small"> <u>R</u>elationship  with <u>A</u>ddiction <u>T</u>hrough <u>S</u>earches of <u>Pub</u>Med </span></a>
-  <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
+  	<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
     <span class="navbar-toggler-icon"></span>
   </button>
 </nav>
@@ -27,6 +26,7 @@
 
 <script src="https://code.jquery.com/jquery-3.3.1.slim.min.js" integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo" crossorigin="anonymous"></script>
 <script src="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/js/bootstrap.min.js" integrity="sha384-JjSmVgyd0p3pXB1rRibZUAYoIIy6OrQ6VrjIEaFf/nJGzIxFDsf4x0xIM+B07jRM" crossorigin="anonymous"></script>
+<script src="https://cdnjs.cloudflare.com/ajax/libs/cytoscape/3.6.0/cytoscape.min.js" integrity="sha256-uZV2wRlscgr52q3Wb3Oew0rKCPsM3g4aBTv46sF4qzg=" crossorigin="anonymous"></script>
 </body>