Permalink
Fetching contributors…
Cannot retrieve contributors at this time
368 lines (339 sloc) 11.2 KB
<!DOCTYPE html>
<html>
<head>
<link rel="stylesheet" type="text/css" media="screen" href="/css/arXiv.css" />
<title> {{- paper.title -}} </title>
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js">
</script>
<script type="text/javascript" src="//cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML,Safe">
</script>
<script type="text/javascript">
function setInterest(topicID, state, userID)
{
$.post("/papers/ {{- paper._id -}} /likes/" + userID,
{
topic:topicID,
state:state
});
}
function toggleInterest(o, userID)
{
if (o.value == "1")
{
o.value="0";
alert('Your interest tag has been removed from this paper.');
}
else
{
o.value="1";
alert('Your interest tag has been added to this paper.');
}
setInterest(o.name, o.value, userID);
}
function toggleReadingList(o, userID)
{
if (o.value == "1")
{
o.value="0";
alert('This paper has been removed from your reading list.');
}
else
{
o.value="1";
alert('This paper has been added to your reading list.');
}
$.post("/people/" + userID + "/reading/" + "{{- paper._id -}}",
{
state:o.value
});
}
function validateForm()
{
var topic=document.forms["topicForm"]["topic"].value;
var topic2=document.forms["topicForm"]["topic2"].value;
if ((topic==null || topic=="") && (topic2==null || topic2==""))
{
alert("You must either choose a topic from the list, or type a new topic name.");
return false;
}
}
</script>
</head>
<body>
<div id="header">
<h1><img src="/favicon.ico"/><a href="/">SelectedPapers.net</a> &gt;
{% if hasattr(paper, 'arxiv') %}
<a href="http://arxiv.org">arXiv.org</a> &gt; <a href=" {{- paper.get_value('source_url') -}} "> {{- paper.arxiv.id.replace('_', '/') -}} </a>
{% elif hasattr(paper, 'pubmed') %}
<a href="http://www.ncbi.nlm.nih.gov/pubmed">Pubmed</a> &gt; <a href=" {{- paper.get_value('source_url') -}} "> {{- paper.pubmed.id -}} </a>
{% elif hasattr(paper, 'doi') %}
<a href="http://www.crossref.org/guestquery/">DOI</a> &gt; <a href=" {{- paper.get_value('source_url') -}} "> {{- paper.doi.id -}} </a>
(<A href="http://shortdoi.org/">short DOI</A>)
{% endif %}
</h1>
<form id="search" method="GET" action="/papers">
<div class="search-for">Search or Article-id</div>
<div class="links">(<a href="http://docs.selectedpapers.net">Help</a> | <a href="http://arxiv.org/find">Advanced search</a>)
{% if user %}
| <a href="/signout">Signout</a>
{% endif %}
</div>
<input type="text" name="searchString" size="24" maxlength="256" />
&nbsp;
<select name="searchType">
<option value="arxiv" selected="selected">arXiv</option>
<option value="arxivID">arXiv ID</option>
<option value="DOI">DOI</option>
<option value="shortDOI">Short DOI</option>
<option value="PMID">Pubmed ID</option>
<option value="pubmed">Pubmed</option>
<option value="ncbipubmed">Pubmed (ncbi)</option>
<option value="spnetPerson">People on spnet</option>
<option value="topic">Topics on spnet</option>
<option value="comment">Comments on spnet</option>
</select>
<input type="submit" value="Go!" /><br />
</form>
</div>
<div id="content">
<div id="abs">
<div class="extra-services">
<div class="full-text">
<h2>Next Steps:</h2>
<ul>
<li><a href=" {{- paper.get_value('downloader_url') -}} " title="View this paper in PDF format">Full text</a></li>
<li><a href="{{- paper.get_value('source_url') -}}">
{{- paper.get_value('doctag') -}}</a></li>
</ul>
{% if user %}
<input type="checkbox" name="readingList"
onclick="toggleReadingList(this, ' {{- user._id -}} ')"
{% if paper._id in user._dbDocDict.get('readingList', ()) %}
value="1" CHECKED
{% else %}
value="0"
{% endif %}
/> Add to my Reading List
{% endif %}
{% if hasattr(paper, 'arxiv') %}
<form id="dollarToggle" method="POST" action=" {{- paper.get_value('local_url') -}} ">
{% set showLatex = kwargs.get('showLatex', {}).get(paper, 'NULL') %}
{% if showLatex == 'NULL' %}
{% set showLatex = (getattr(paper, 'texDollars', 0) > 2) %}
{% endif %}
{% if showLatex %}
<INPUT TYPE="hidden" NAME="showLatex" VALUE="0" />
<INPUT TYPE="submit" value="Don't treat $ as inline math"
title="Click this to stop treating $ as inline math delimiter."/>
{% else %}
<INPUT TYPE="hidden" NAME="showLatex" VALUE="1" />
<INPUT TYPE="submit" value="Treat $ as inline math"
title="Click this to display $inlinemath$ as equations."/>
{% endif %}
</form>
{% else %}
{% set showLatex = 0 %}
{% endif %}
</div><!--end full-text-->
<div class="browse">
<h3>Tagged as interesting for:</h3>
{% for topicID, people in paper.get_interests(sorted=True) %}
{% if user %}
<input type="checkbox" name="{{- topicID -}}"
onclick="toggleInterest(this, ' {{- user._id -}} ')"
{% if user in people %}
value="1" CHECKED
{% else %}
value="0"
{% endif %}
/>
{% endif %}
<A HREF="/topics/{{- topicID -}}">
{{ '#' + topicID }}
</A> (by {{ list_people(people) -}} )
<BR>
{% endfor %}
{% if user %}
(Click a checkbox to tag paper as interesting for your work in that area)
<hr>
<FORM name="topicForm" action="{{- '/papers/%s/likes/%s' % (str(paper._id), str(user._id)) -}}" onsubmit="return validateForm()" method="POST">
Or add your topic:
<select name="topic2">
<option value=""></option>
{% for topicID,papers in user.get_interests(sorted=True) %}
<option value=" {{- topicID -}} "> {{- '#' + topicID -}} </option>
{% endfor %}
</select>
<BR>
or enter a new tag here:
<INPUT TYPE="hidden" NAME="state" VALUE="1" />
<INPUT TYPE="text" id="addNewTopic" NAME="topic" SIZE=15/>
<INPUT TYPE="submit" value="Save" />
</FORM>
{% endif %}
</div>
<div class="extra-ref-cite">
{% if user %}
Welcome
<a href=" {{- user.get_local_url() -}} "> {{- user.name -}} </a>
{% else %}
Use your Google sign-in to tag, share, discuss and recommend papers:
<BR>
<A HREF="/gplus_login"><IMG SRC="/images/Red-signin_Long_base_20dp.png"></A>
{% endif %}
</div>
<div class="bookmarks">
<h3>Share This Paper</h3>
<a href="https://plus.google.com/share? {{- urlencode(dict(url=paper.get_value())) -}}" onclick="javascript:window.open(this.href, '', 'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=600,width=600');return false;">
<img src="https://www.gstatic.com/images/icons/gplus-32.png" alt="Share on Google+" title="Share this paper on Google+"/></a>
</div>
</div><!--end extra-services-->
<div class="leftcolumn">
<h1 class="title">
{{ paper.title }}
</h1>
<div class="authors">
{{ ', '.join(paper.authorNames) }}
</div>
<blockquote class="abstract">
{{ paper.get_value('abstract', showLatex=showLatex) }}
</blockquote>
<div class="submission-history">
<h2>Recommendations
{% if user %}
<button
class="g-interactivepost"
data-contenturl=" {{- paper.get_value() -}} "
data-clientid=" {{- gplusClientID -}} "
data-cookiepolicy="single_host_origin"
data-prefilltext="[WRITE YOUR RECOMMENDATION HERE] #spnetwork #recommend {{ paper.get_value('doctag') + ' #'.join([''] + user.get_interests().keys()) -}}"
data-calltoactionlabel="VIEW"
data-calltoactionurl=" {{- paper.get_value() -}} "
title="Click to recommend this paper on Google+">
Write recommendation
</button>
<button
class="g-interactivepost"
data-contenturl=" {{- paper.get_value() -}} "
data-clientid=" {{- gplusClientID -}} "
data-cookiepolicy="single_host_origin"
data-prefilltext="[WRITE YOUR RECOMMENDATION HERE] #spnetwork #mustread {{ paper.get_value('doctag') + ' #'.join([''] + user.get_interests().keys()) -}}"
data-calltoactionlabel="VIEW"
data-calltoactionurl=" {{- paper.get_value() -}} "
title="Click to recommend this paper as MUST-READ for your area of research">
Recommend as Must-Read
</button>
{% endif %}
</h2>
<dl>
{% for i,rec in enumerate(timesort(paper.get_all_posts(True))) %}
<dt>[
<A HREF="{{- rec.get_local_url() -}} ">
{{- i + 1 -}} </A> ]
<A HREF="{{- rec.get_author_url() -}}">
{{ rec.get_author_name() }}
</A>: <B>{{ rec.title }}</B> ( {{- display_datetime(rec.published) -}} )
<a href="https://plus.google.com/share? {{- urlencode(dict(url=rec.get_spnet_url())) -}}" onclick="javascript:window.open(this.href, '', 'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=600,width=600');return false;">
<img src="https://www.gstatic.com/images/icons/gplus-32.png" alt="Share on Google+" title="Share this recommendation on Google+"/></a>
{% if hasattr(rec, 'url') %}
<a href=" {{- rec.url -}} " onclick="javascript:window.open(this.href, '', 'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=600,width=800');return false;">
<img src="/images/reply.jpg" title="Click here to reply to this comment on Google+"></a>
{% endif %}
</dt>
<dd>
{% if rec.sigs %}
<span class="list-identifier">Recommended for:
{% for topic in rec.sigs %}
<A HREF="{{- topic.get_local_url() -}}"> {{ topic.name }} </A>
{% endfor %}
</span>
{% endif %}
<div class="list-comments">
<input type="checkbox" id="rectoggle {{- i -}}"/>Show discussion.<BR>
<div id="rectext {{- i -}}" style="display: none">
{{ rec.get_text() }}
{% for reply in timesort(rec.get_replies(), reverse=False) %}
<li><A HREF="{{- reply.get_author_url() -}}">
{{ reply.get_author_name() }}
</A> replies ( {{- display_datetime(reply.published) -}} ):
{{ reply.get_text() }}
</li>
{% endfor %}
</div>
</div>
</dd>
<script>
$( "#rectoggle {{- i -}}" ).click(function() {
$( "#rectext {{- i -}}" ).toggle();
});
</script>
{% endfor %}
</dl>
<h2>Discussion
{% if user %}
<button
class="g-interactivepost"
data-contenturl=" {{- paper.get_value() -}} "
data-clientid=" {{- gplusClientID -}} "
data-cookiepolicy="single_host_origin"
data-prefilltext="[YOUR QUESTION HERE] #spnetwork {{ paper.get_value('doctag') -}}"
data-calltoactionlabel="VIEW"
data-calltoactionurl=" {{- paper.get_value() -}} "
title="Click to post a question or comment about this paper on Google+">
Discuss this paper
</button>
{% endif %}
</h2>
<dl>
{% for i,post in enumerate(timesort(paper.get_all_posts())) %}
<dt>[ {{- i + 1 -}} ]
<A HREF="{{- post.get_author_url() -}}">
{{ post.get_author_name() }}
</A>
{% if post.sigs %}
on topics:
{% for topic in post.sigs %}
<A HREF="{{- topic.get_local_url() -}}"> {{ topic.name }} </A>
{% endfor %}
{% endif %}
( {{- display_datetime(post.published) -}} )
</dt>
<dd>
<div class="list-comments">
<input type="checkbox" id="disctoggle {{- i -}}"/>Show discussion.<BR>
<div id="disctext {{- i -}}" style="display: none">
{{ post.get_text() }}
{% if hasattr(post, 'url') %}
<a href=" {{- post.url -}} " onclick="javascript:window.open(this.href, '', 'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=600,width=800');return false;">
<img src="/images/reply.jpg" title="Click here to reply to this comment on Google+"></a>
{% endif %}
{% for reply in timesort(post.get_replies(), reverse=False) %}
<li><A HREF="{{- reply.get_author_url() -}}">
{{ reply.get_author_name() }}
</A> replies ( {{- display_datetime(reply.published) -}} ):
{{ reply.get_text() }}
</li>
{% endfor %}
</div>
</div>
</dd>
<script>
$( "#disctoggle {{- i -}}" ).click(function() {
$( "#disctext {{- i -}}" ).toggle();
});
</script>
{% endfor %}
</dl>
</div>
</div><!--end leftcolumn-->
</div><!--end abs-->
</div>
<script type="text/javascript">
(function() {
var po = document.createElement('script'); po.type = 'text/javascript'; po.async = true;
po.src = 'https://apis.google.com/js/client:plusone.js';
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(po, s);
})();
</script>
</body>
</html>