gnunetbib

Bibliography (BibTeX, based on AnonBib)
Log | Files | Refs | README | LICENSE

commit 2b04ba1aed965974ea46fb5ef75e033384a68160
parent dc27c9654d332e16df46be2215bfcaa82a7023b1
Author: Steven Murdoch <Steven.Murdoch@cl.cam.ac.uk>
Date:   Sun, 22 Mar 2009 12:21:30 +0000

When generating full/bibtex.html, reference the correct CSS files

svn:r317

Diffstat:
M_template_bibtex.html | 4++--
MwriteHTML.py | 9++++++++-
2 files changed, 10 insertions(+), 3 deletions(-)

diff --git a/_template_bibtex.html b/_template_bibtex.html @@ -14,8 +14,8 @@ <title>%(title)s: BibTeX</title> -<link rel="stylesheet" type="text/css" href="./css/main.css" /> -<link rel="stylesheet" type="text/css" href="./css/pubs.css" /> +<link rel="stylesheet" type="text/css" href="%(root)s/css/main.css" /> +<link rel="stylesheet" type="text/css" href="%(root)s/css/pubs.css" /> </head> <body bgcolor="#ffffff" text="#000000" link="#bb0000" vlink="#990099" diff --git a/writeHTML.py b/writeHTML.py @@ -199,10 +199,17 @@ def writePageSet(config, bib, tag): entries = [ (ent.key, ent) for ent in entries ] entries.sort() entries = [ ent[1] for ent in entries ] + + ## Finding the root directory is done by writeHTML(), but + ## the BibTeX file doesn't use that, so repeat the code here + root = "../"*pathLength(config.TAG_DIRECTORIES[tag]) + if root == "": root = "." + header,footer = getTemplate(config.BIBTEX_TEMPLATE_FILE) f = open(os.path.join(outdir,"bibtex.html"), 'w') print >>f, header % { 'command_line' : "", - 'title': config.TAG_TITLES[tag] } + 'title': config.TAG_TITLES[tag], + 'root': root } for ent in entries: print >>f, ( ("<tr><td class='bibtex'><a name='%s'>%s</a>"