-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMarohnGroup-20210331-132547--Installing-and-configuring-Zotero.html
371 lines (307 loc) · 24.8 KB
/
MarohnGroup-20210331-132547--Installing-and-configuring-Zotero.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" type="text/css" href="https://marohn.chem.cornell.edu/theme/css/elegant.prod.9e9d5ce754.css" media="screen">
<link rel="stylesheet" type="text/css" href="https://marohn.chem.cornell.edu/theme/css/custom.css" media="screen">
<link rel="dns-prefetch" href="//fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com/" crossorigin>
<meta name="author" content="John A. Marohn ([email protected])" />
<meta property="og:type" content="article" />
<meta name="twitter:card" content="summary">
<meta name="keywords" content="research, LaTeX, BibTeX, Zotero, research, " />
<meta property="og:title" content="Installing and configuring Zotero for use with LaTeX "/>
<meta property="og:url" content="https://marohn.chem.cornell.edu/MarohnGroup-20210331-132547--Installing-and-configuring-Zotero.html" />
<meta property="og:description" content="Background Our group writes its papers and grants in LaTeX. We edit LateX documents collaboratively using either (1) Overleaf or (2) by pushing and pulling from a private git repository shared via Dropbox (described here). For fast real-time editing of projects like grants, the group likes Overleaf because of its …" />
<meta property="og:site_name" content="The Marohn Group" />
<meta property="og:article:author" content="John A. Marohn ([email protected])" />
<meta property="og:article:published_time" content="2021-03-31T13:25:00-04:00" />
<meta property="og:article:modified_time" content="2023-09-01T17:15:52.909471-04:00" />
<meta name="twitter:title" content="Installing and configuring Zotero for use with LaTeX ">
<meta name="twitter:description" content="Background Our group writes its papers and grants in LaTeX. We edit LateX documents collaboratively using either (1) Overleaf or (2) by pushing and pulling from a private git repository shared via Dropbox (described here). For fast real-time editing of projects like grants, the group likes Overleaf because of its …">
<title>Installing and configuring Zotero for use with LaTeX · The Marohn Group
</title>
</head>
<body>
<div id="content">
<div class="navbar navbar-static-top">
<div class="navbar-inner">
<div class="container-fluid">
<a class="btn btn-navbar" data-toggle="collapse" data-target=".nav-collapse">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</a>
<a class="brand" href="https://marohn.chem.cornell.edu/"><span class=site-name>The Marohn Group</span></a>
<div class="nav-collapse collapse">
<ul class="nav pull-right top-menu">
<li >
<a href=
https://marohn.chem.cornell.edu
>Home</a>
</li>
<li ><a href="https://marohn.chem.cornell.edu/pages/1-Research.html">Research</a></li>
<li ><a href="https://marohn.chem.cornell.edu/pages/2-Publications.html">Publications</a></li>
<li ><a href="https://marohn.chem.cornell.edu/pages/3-PI.html">Prof. Marohn</a></li>
<li ><a href="https://marohn.chem.cornell.edu/pages/4-Group.html">Group Members</a></li>
<li ><a href="https://marohn.chem.cornell.edu/pages/5-Links.html">Links</a></li>
<li ><a href="https://marohn.chem.cornell.edu/categories.html">Categories</a></li>
<li ><a href="https://marohn.chem.cornell.edu/tags.html">Tags</a></li>
<li ><a href="https://marohn.chem.cornell.edu/archives.html">Archives</a></li>
<li><form class="navbar-search" action="https://marohn.chem.cornell.edu/search.html" onsubmit="return validateForm(this.elements['q'].value);"> <input type="text" class="search-query" placeholder="Search" name="q" id="tipue_search_input"></form></li>
</ul>
</div>
</div>
</div>
</div>
<div class="container-fluid">
<div class="row-fluid">
<div class="span1"></div>
<div class="span10">
<article itemscope>
<div class="row-fluid">
<header class="page-header span10 offset2">
<h1>
<a href="https://marohn.chem.cornell.edu/MarohnGroup-20210331-132547--Installing-and-configuring-Zotero.html">
Installing and configuring Zotero for use with LaTeX
</a>
</h1>
</header>
</div>
<div class="row-fluid">
<div class="span2 table-of-content">
<nav>
<h4>Contents</h4>
<div class="toc" id="">
<p class="topic-title">Contents</p>
<ul class="simple">
<li><a class="reference internal" href="#background" id="toc-entry-1">Background</a></li>
<li><a class="reference internal" href="#the-zotero-application" id="toc-entry-2">The Zotero application</a></li>
<li><a class="reference internal" href="#the-connector-plug-in" id="toc-entry-3">The Connector plug-in</a></li>
<li><a class="reference internal" href="#the-better-bibtex-extension" id="toc-entry-4">The Better BibTeX extension</a></li>
<li><a class="reference internal" href="#playing-nice-with-latex" id="toc-entry-5">Playing nice with LaTeX</a></li>
</ul>
</div>
</nav>
</div>
<div class="span8 article-content">
<div class="section" id="background">
<h2><a class="toc-backref" href="#toc-entry-1">Background</a></h2>
<p>Our group writes its papers and grants in LaTeX. We edit LateX documents collaboratively using either (1) <a class="reference external" href="https://www.overleaf.com">Overleaf</a> or (2) by pushing and pulling from a private <a class="reference external" href="https://git-scm.com/">git</a> repository shared via Dropbox (described <a class="reference external" href="http://marohn-public.site44.com/Marohn-20141222-112301--Working-with-git.html">here</a>). For fast real-time editing of projects like grants, the group likes Overleaf because of its commenting, track changes, and chat features. It also has <tt class="docutils literal">git</tt> support, so you can work offline if you don’t want to edit in public or if the project requires major surgery. For collaborative editing we tried <a class="reference external" href="https://www.authorea.com">Authorea</a>, but found it inadequate (discussed <a class="reference external" href="http://marohn-public.site44.com/Marohn-20180319-082229--Authorea-and-Github.html">here</a>).</p>
<p>We use BibTeX or Biber to create bibliographies. References have so far been handled by each coauthor individually, with each coauthor contributing a <tt class="docutils literal">.bib</tt> file to the project directory. Most of us have been reading and editing our <tt class="docutils literal">.bib</tt> files using the free, open-source <a class="reference external" href="https://www.jabref.org">JabRef</a> application. For sharing references, we have begun using <a class="reference external" href="https://www.zotero.org">Zotero</a>. It is likewise open-source but allows you to share references. It has quite good BibTeX support.</p>
<p>The purpose of this memo is to summarize how to install and configure Zotero to create high-quality <tt class="docutils literal">.bib</tt> files for use with LaTeX.</p>
</div>
<div class="section" id="the-zotero-application">
<h2><a class="toc-backref" href="#toc-entry-2">The Zotero application</a></h2>
<p>Zotero is <em>both</em> a desktop application and a web application. As explained <a class="reference external" href="https://www.zotero.org/why">here</a>, you do not need to register for a free web-application account to use Zotero. However,</p>
<blockquote>
If you choose to create an account and sync your data, you’ll also have access to your web library on zotero.org. However, while the web library allows you to view and edit your data and access synced files, for full functionality you’ll want to install Zotero on each synced computer.</blockquote>
<p>I decide to register for a free account <a class="reference external" href="https://www.zotero.org/user/login/">here</a> for my research group. This allows me to synchronize the local copy of my references with a copy on the web and, more importantly, allows me to share a library with my students and collaborators.</p>
<p>Now download the Zotero application from <a class="reference external" href="https://www.zotero.org/download/">here</a> and install it. It asks for an admin password (in macOS at least). I am now running the “Zotero 5.0 for Mac” desktop application.</p>
</div>
<div class="section" id="the-connector-plug-in">
<h2><a class="toc-backref" href="#toc-entry-3">The Connector plug-in</a></h2>
<p>Zotero’s killer feature is its ability to create a reference from a journal web page. To access this feature, you need to install an add-on for your web browser. My default web browser is Safari. After reading <a class="reference external" href="https://www.zotero.org/support/kb/safari_compatibility">here</a>, I
think it best to use Zotero with the Firefox or Chrome browser instead.</p>
<p>Boot the Google Chrome browser, go to the Zotero <a class="reference external" href="https://www.zotero.org/download/">downloads</a> web page, and click on [Install Chrome Connector] on the right-hand side of the page.</p>
<p>Now configure the extension to sync with the web account and check that the extension is running. In Google Chrome,</p>
<pre class="literal-block">
Chrome > Preferences > Extensions (lower left)
</pre>
<p>then</p>
<pre class="literal-block">
Zotero Connector > [Details] > Extension options > Save to Zotero.org
</pre>
<p>and enter my Zotero user email and password. In <tt class="docutils literal">Extension options</tt>, under <tt class="docutils literal">Zotero Status</tt>, it says “Zotero is currently available”. The Zotero application has to be running or else this message says “Zotero is currently unavailable.”</p>
</div>
<div class="section" id="the-better-bibtex-extension">
<h2><a class="toc-backref" href="#toc-entry-4">The Better BibTeX extension</a></h2>
<p>As installed so far, Zotero will save your references to a <tt class="docutils literal">.bib</tt> file. However, the entries in the <tt class="docutils literal">.bib</tt> file will have strange citation keys, will contain fields which you don’t need and which will confuse BibTeX, and special characters will not have been converted to LaTeX. The <a class="reference external" href="https://retorque.re/zotero-better-bibtex/">Better BibTeX extension</a> fixes all these problems.</p>
<p>Follow the Better BibTeX extension intallation instructions <a class="reference external" href="https://retorque.re/zotero-better-bibtex/installation/">here</a>. Reboot Zotero.</p>
<p>Choose “Use the <span class="caps">BBT</span> default citekey format”, continue; click “Enable drag-and-drop citations”, continue; unclick “Unabbreviate journal names on import, click “Expand @string journal names on import, continue; note that I want to select “Better BibTeX” and not “BibTex” as the export format in Zotero, continue. New translators are automatically installed. Reboot Zotero.</p>
<p>Now tweak the Better BibTeX preferences. Go to</p>
<pre class="literal-block">
Zotero > Preferences > Better BibteX
</pre>
<p>and adjust the following settings from their default values.</p>
<p>Citation keys:</p>
<ul class="simple">
<li>Citation key format: [Auth][year][month]</li>
<li>[x] Force citation to be plain text</li>
<li>Keep keys unique: within each library</li>
<li>On conflict with a pinned key, non-pinned keys will be: postfixed
(causes key changes)</li>
</ul>
<p>Export:</p>
<ul class="simple">
<li>Add URLs to BibTeX export: in the ‘url’ field</li>
</ul>
<p>Fields:</p>
<ul class="simple">
<li>When a reference has both a <span class="caps">DOI</span> and a <span class="caps">URL</span>, export: both</li>
<li>Fields to omit from export (comma separated): issn, abstract, urldate, note, publisher, groups, timestamp, copyright, chapter, pmid, file, shorttitle, language, keywords</li>
<li>Include JabRef-specified metadata: no</li>
</ul>
<p>Miscellaneous:</p>
<ul class="simple">
<li>[x] Automatically abbreviate journal title if none is set explicitly</li>
<li>[x] Include comments about potential problems with the references</li>
<li>[x] Include automatic tags in export</li>
</ul>
<p>Advanced. Export:</p>
<ul class="simple">
<li>[x] Apply title-casing to titles</li>
<li>[ ] Apply case-protection to capitalized words by enclosing them in braces</li>
</ul>
<p>Now when you export a library in “Better BibTeX” format, the resulting <tt class="docutils literal">.bib</tt> file should be well behaved.</p>
</div>
<div class="section" id="playing-nice-with-latex">
<h2><a class="toc-backref" href="#toc-entry-5">Playing nice with LaTeX</a></h2>
<p>Some references still to be touched up. Here is an example: <a class="reference external" href="https://doi.org/10.1002/adfm.202005662"><span class="caps">DOI</span>:10.1002/adfm.202005662</a>. In this example, we need “2D” and “Ruddelson-Popper” to be properly capitalized in the title, and probably we want the first dash in the title to be replaced by a long dash.</p>
<p>There are two way to achieve these modifications:</p>
<ol class="arabic simple">
<li>In the <tt class="docutils literal">.bib</tt> file, we really want the title to read “{2D}” and “{R}uddelson-{P}opper”. As explained <a class="reference external" href="https://retorque.re/zotero-better-bibtex/">here</a>, any text between “<script>” and “</script>” is treated as literal LaTeX text upon export and is left alone. So in the title, replace “2D” with “<script>{</script>2D<script>}</script>”. Use this same trick to achieve “{R}” and “{P}” and to replace the dash by “—-“. This kludge works, but the article title is now essentially unreadable in Zotero. There is an easier way.</li>
<li>Any entry tagged with <tt class="docutils literal">#LaTeX</tt> (case-sensitive!) will have all fields exported as if they are wrapped in “<script>…</script>”, so you can include LaTeX markup in your references directly (see <a class="reference external" href="https://retorque.re/zotero-better-bibtex/exporting/advanced/">here</a>). This is the easier solution. In the above example, add the <tt class="docutils literal">#LaTeX</tt> tag to the reference and edit the title to be what we would want in LaTeX, “Light-dependent impedance spectra and transient photoconductivity in a {R}uddlesden—-{P}opper {2D} Lead–Halide perovskite revealed by electrical scanned probe microscopy and accompanying theory”. The title will again export properly but is now readable in Zotero.</li>
</ol>
<p>Using these tricks I can touch up the article title in Zotero before export and not have to mess with the <tt class="docutils literal">.bib</tt> file after export.</p>
<!-- restview content/research/MarohnGroup-20210331-132547- -Installing-and-configuring-Zotero.rst -->
</div>
<p id="post-share-links">
Share on:
<a href="mailto:?subject=Installing%20and%20configuring%20Zotero%20for%20use%20with%C2%A0LaTeX&body=https%3A//marohn.chem.cornell.edu/MarohnGroup-20210331-132547--Installing-and-configuring-Zotero.html" target="_blank" rel="nofollow noopener noreferrer" title="Share via Email">Email</a>
❄ <a href="https://www.linkedin.com/shareArticle?mini=true&url=https%3A//marohn.chem.cornell.edu/MarohnGroup-20210331-132547--Installing-and-configuring-Zotero.html&title=Installing%20and%20configuring%20Zotero%20for%20use%20with%C2%A0LaTeX&summary=Background%0AOur%20group%20writes%20its%20papers%20and%20grants%20in%20LaTeX.%20%20We%20edit%20LateX%20documents%20collaboratively%20using%20either%20%281%29%20Overleaf%20or%20%282%29%20by%20pushing%20and%20pulling%20from%20a%20private%20git%20repository%20shared%20via%20Dropbox%20%28described%20here%29.%20%20For%20fast%20real-time%20editing%20of%20projects%20like%20grants%2C%20the%20group%20likes%20Overleaf%20because%20of%20its%20%E2%80%A6&source=https%3A//marohn.chem.cornell.edu/MarohnGroup-20210331-132547--Installing-and-configuring-Zotero.html" target="_blank" rel="nofollow noopener noreferrer" title="Share on LinkedIn">LinkedIn</a>
❄ <a href="https://twitter.com/intent/tweet?text=Installing%20and%20configuring%20Zotero%20for%20use%20with%C2%A0LaTeX&url=https%3A//marohn.chem.cornell.edu/MarohnGroup-20210331-132547--Installing-and-configuring-Zotero.html&hashtags=research,latex,bibtex,zotero" target="_blank" rel="nofollow noopener noreferrer" title="Share on Twitter">Twitter</a>
❄ <a href="https://www.facebook.com/sharer/sharer.php?u=https%3A//marohn.chem.cornell.edu/MarohnGroup-20210331-132547--Installing-and-configuring-Zotero.html" target="_blank" rel="nofollow noopener noreferrer" title="Share on Facebook">Facebook</a>
<hr/>
</div>
<section id="article-sidebar" class="span2">
<h4>Published</h4>
<time itemprop="dateCreated" datetime="2021-03-31T13:25:00-04:00">Wed 31 March 2021</time>
<h4>Last Updated</h4>
<time datetime="2023-09-01T17:15:52.909471-04:00">Sep 1, 2023</time>
<h4>Category</h4>
<a class="category-link" href="https://marohn.chem.cornell.edu/categories.html#research-ref">research</a>
<h4>Tags</h4>
<ul class="list-of-tags tags-in-article">
<li><a href="https://marohn.chem.cornell.edu/tags.html#bibtex-ref">BibTeX
<span class="superscript">1</span>
</a></li>
<li><a href="https://marohn.chem.cornell.edu/tags.html#latex-ref">LaTeX
<span class="superscript">1</span>
</a></li>
<li><a href="https://marohn.chem.cornell.edu/tags.html#research-ref">research
<span class="superscript">16</span>
</a></li>
<li><a href="https://marohn.chem.cornell.edu/tags.html#zotero-ref">Zotero
<span class="superscript">1</span>
</a></li>
</ul>
<h4>Stay in Touch</h4>
<div id="sidebar-social-link">
<a href="mailto:[email protected]" title="Marohn email address" target="_blank" rel="nofollow noopener noreferrer">
<svg xmlns="http://www.w3.org/2000/svg" aria-label="Mail" role="img" viewBox="0 0 512 512"><rect width="512" height="512" rx="15%" fill="#328cff"/><path d="m250 186c-46 0-69 35-69 74 0 44 29 72 68 72 43 0 73-32 73-75 0-44-34-71-72-71zm-1-37c30 0 57 13 77 33 0-22 35-22 35 1v150c-1 10 10 16 16 9 25-25 54-128-14-187-64-56-149-47-195-15-48 33-79 107-49 175 33 76 126 99 182 76 28-12 41 26 12 39-45 19-168 17-225-82-38-68-36-185 67-248 78-46 182-33 244 32 66 69 62 197-2 246-28 23-71 1-71-32v-11c-20 20-47 32-77 32-57 0-108-51-108-108 0-58 51-110 108-110" fill="#fff"/></svg>
</a>
<a href="https://github.com/JohnMarohn/" title="Marohn Github repository" target="_blank" rel="nofollow noopener noreferrer">
<svg xmlns="http://www.w3.org/2000/svg" aria-label="GitHub" role="img" viewBox="0 0 512 512"><rect width="512" height="512" rx="15%" fill="#1B1817"/><path fill="#fff" d="M335 499c14 0 12 17 12 17H165s-2-17 12-17c13 0 16-6 16-12l-1-50c-71 16-86-28-86-28-12-30-28-37-28-37-24-16 1-16 1-16 26 2 40 26 40 26 22 39 59 28 74 22 2-17 9-28 16-35-57-6-116-28-116-126 0-28 10-51 26-69-3-6-11-32 3-67 0 0 21-7 70 26 42-12 86-12 128 0 49-33 70-26 70-26 14 35 6 61 3 67 16 18 26 41 26 69 0 98-60 120-117 126 10 8 18 24 18 48l-1 70c0 6 3 12 16 12z"/></svg>
</a>
<a href="https://www.linkedin.com/in/john-marohn-1535431a/" title="Marohn LinkedIn profile" target="_blank" rel="nofollow noopener noreferrer">
<svg xmlns="http://www.w3.org/2000/svg" aria-label="LinkedIn" role="img" viewBox="0 0 512 512" fill="#fff"><rect width="512" height="512" rx="15%" fill="#0077b5"/><circle cx="142" cy="138" r="37"/><path stroke="#fff" stroke-width="66" d="M244 194v198M142 194v198"/><path d="M276 282c0-20 13-40 36-40 24 0 33 18 33 45v105h66V279c0-61-32-89-76-89-34 0-51 19-59 32"/></svg>
</a>
</div>
</section>
</div>
</article>
<!-- Root element of PhotoSwipe. Must have class pswp. -->
<div class="pswp" tabindex="-1" role="dialog" aria-hidden="true">
<!-- Background of PhotoSwipe.
It's a separate element as animating opacity is faster than rgba(). -->
<div class="pswp__bg"></div>
<!-- Slides wrapper with overflow:hidden. -->
<div class="pswp__scroll-wrap">
<!-- Container that holds slides.
PhotoSwipe keeps only 3 of them in the DOM to save memory.
Don't modify these 3 pswp__item elements, data is added later on. -->
<div class="pswp__container">
<div class="pswp__item"></div>
<div class="pswp__item"></div>
<div class="pswp__item"></div>
</div>
<!-- Default (PhotoSwipeUI_Default) interface on top of sliding area. Can be changed. -->
<div class="pswp__ui pswp__ui--hidden">
<div class="pswp__top-bar">
<!-- Controls are self-explanatory. Order can be changed. -->
<div class="pswp__counter"></div>
<button class="pswp__button pswp__button--close" title="Close (Esc)"></button>
<button class="pswp__button pswp__button--share" title="Share"></button>
<button class="pswp__button pswp__button--fs" title="Toggle fullscreen"></button>
<button class="pswp__button pswp__button--zoom" title="Zoom in/out"></button>
<!-- Preloader demo https://codepen.io/dimsemenov/pen/yyBWoR -->
<!-- element will get class pswp__preloader--active when preloader is running -->
<div class="pswp__preloader">
<div class="pswp__preloader__icn">
<div class="pswp__preloader__cut">
<div class="pswp__preloader__donut"></div>
</div>
</div>
</div>
</div>
<div class="pswp__share-modal pswp__share-modal--hidden pswp__single-tap">
<div class="pswp__share-tooltip"></div>
</div>
<button class="pswp__button pswp__button--arrow--left" title="Previous (arrow left)">
</button>
<button class="pswp__button pswp__button--arrow--right" title="Next (arrow right)">
</button>
<div class="pswp__caption">
<div class="pswp__caption__center"></div>
</div>
</div>
</div>
</div> </div>
<div class="span1"></div>
</div>
</div>
</div>
<footer>
<div id="fpowered">
Powered by: <a href="http://getpelican.com/" title="Pelican Home Page" target="_blank" rel="nofollow noopener noreferrer">Pelican</a>
Theme: <a href="https://elegant.oncrashreboot.com/" title="Theme Elegant Home Page" target="_blank" rel="nofollow noopener noreferrer">Elegant</a>
</div>
</footer> <script src="//code.jquery.com/jquery.min.js"></script>
<script src="//netdna.bootstrapcdn.com/twitter-bootstrap/2.3.2/js/bootstrap.min.js"></script>
<script src="https://marohn.chem.cornell.edu/theme/js/elegant.prod.9e9d5ce754.js"></script>
<script>
function validateForm(query)
{
return (query.length > 0);
}
</script>
<script>
(function () {
if (window.location.hash.match(/^#comment-\d+$/)) {
$('#comment_thread').collapse('show');
}
})();
window.onhashchange=function(){
if (window.location.hash.match(/^#comment-\d+$/))
window.location.reload(true);
}
$('#comment_thread').on('shown', function () {
var link = document.getElementById('comment-accordion-toggle');
var old_innerHTML = link.innerHTML;
$(link).fadeOut(200, function() {
$(this).text('Click here to hide comments').fadeIn(200);
});
$('#comment_thread').on('hidden', function () {
$(link).fadeOut(200, function() {
$(this).text(old_innerHTML).fadeIn(200);
});
})
})
</script>
</body>
<!-- Theme: Elegant built for Pelican
License : MIT -->
</html>