diff options
author | Martin Langhoff <martin@laptop.org> | 2010-10-22 20:54:04 (GMT) |
---|---|---|
committer | Martin Langhoff <martin@laptop.org> | 2010-10-22 20:54:04 (GMT) |
commit | 10ba7f9080390f6b8fed8dae7ca3a10799cf55ea (patch) | |
tree | af6d15e39f7a00214cf4e983cbe6576390ba4076 | |
parent | efbfcad87100f392ba34d41f8027b79286c6d1ee (diff) |
Move header and inappropriate / error links to server.py
-rwxr-xr-x | mwlib/htmlwriter.py | 22 | ||||
-rwxr-xr-x | server.py | 24 |
2 files changed, 23 insertions, 23 deletions
diff --git a/mwlib/htmlwriter.py b/mwlib/htmlwriter.py index a970c9c..d169482 100755 --- a/mwlib/htmlwriter.py +++ b/mwlib/htmlwriter.py @@ -348,28 +348,6 @@ class HTMLWriter(object): writeControl = writeText def writeArticle(self, a): - if a.caption: - self.out.write("<h1>") - self._write(a.caption) - self.out.write(' <font size="1">· <a class="offsite" ') - self.out.write('href="http://es.wikipedia.org/wiki/') - self._write(a.caption) - self.out.write('">De Wikipedia, la enciclopedia libre</a> ') - - # Report rendering problem. - self.out.write('· <a class="offsite" ') - self.out.write('href="http://pullcord.laptop.org:8000/render?q=') - self._write(a.caption) - self.out.write('">Haz clic aquí si esta página contiene errores de presentación</a> ') - - # Report inappropriate content. - self.out.write('· <a class="offsite" ') - self.out.write('href="http://pullcord.laptop.org:8000/report?q=') - self._write(a.caption) - self.out.write('">Esta página contiene material inapropiado</a>') - - self.out.write("</font>") - self.out.write('</h1>') for x in a: self.write(x) @@ -462,7 +462,29 @@ class WikiRequestHandler(SimpleHTTPRequestHandler): htmlout.write("</head>") htmlout.write("<body>") - + + htmlout.write("<h1>") + htmlout.write(title) + htmlout.write(' <font size="1">· <a class="offsite" ') + htmlout.write('href="http://es.wikipedia.org/wiki/') + htmlout.write(title) + htmlout.write('">De Wikipedia, la enciclopedia libre</a> ') + + # Report rendering problem. + htmlout.write('· <a class="offsite" ') + htmlout.write('href="http://pullcord.laptop.org:8000/render?q=') + htmlout.write(title) + htmlout.write('">Haz clic aquí si esta página contiene errores de presentación</a> ') + + # Report inappropriate content. + htmlout.write('· <a class="offsite" ') + htmlout.write('href="http://pullcord.laptop.org:8000/report?q=') + htmlout.write(title) + htmlout.write('">Esta página contiene material inapropiado</a>') + + htmlout.write("</font>") + htmlout.write('</h1>') + self.write_wiki_html(htmlout, title, article_text) htmlout.write('<center>Contenido disponible bajo los términos de la <a href="/static/es-gfdl.html">Licencia de documentación libre de GNU</a>. <br/> Wikipedia es una marca registrada de la organización sin ánimo de lucro Wikimedia Foundation, Inc.<br/><a href="/static/acerca.html">Acerca de Wikipedia</a> </center>') |