/usr/share/doc/python-genshi-doc/examples/tutorial/geddit/templates/info.html is in python-genshi-doc 0.7-3.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
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 | <!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:xi="http://www.w3.org/2001/XInclude"
xmlns:py="http://genshi.edgewall.org/">
<xi:include href="layout.html" />
<head>
<title>${link.title}</title>
<link rel="alternate" type="application/atom+xml" title="Geddit: ${link.title}"
href="${url('/feed/%s/' % link.id)}" />
<script type="text/javascript">
function loadCommentForm(a) {
$.get("${url('/comment/%s/' % link.id)}", {}, function(html) {
var form = a.hide().parent().after(html).next();
function closeForm() {
form.slideUp("fast", function() { a.fadeIn(); form.remove() });
return false;
}
function initForm() {
form.find("input[@name='cancel']").click(closeForm);
form.submit(function() {
var data = form.find("input[@type='text'], textarea").serialize();
$.post("${url('/comment/%s/' % link.id)}", data, function(html) {
var elem = $(html).get(0);
if (/form/i.test(elem.tagName)) {
form.after(elem).remove();
form = $(elem);
initForm();
} else {
if ($("ul.comments").length == 0) {
a.parent().before('<ul class="comments"></ul>');
}
$("ul.comments").append($(elem));
closeForm();
}
});
return false;
});
}
initForm();
});
}
$(document).ready(function() {
$("a.action").click(function() {
loadCommentForm($(this));
return false;
});
});
</script>
</head>
<body class="info">
<h1>${link.title}</h1>
<a href="${link.url}">${link.url}</a><br />
posted by ${link.username} at ${link.time.strftime('%x %X')}<br />
<ul py:if="link.comments" class="comments">
<xi:include href="_comment.html"
py:for="num, comment in enumerate(link.comments)" />
</ul>
<p><a class="action" href="${url('/comment/%s/' % link.id)}">Add comment</a></p>
</body>
</html>
|