81 lines
2.0 KiB
HTML
81 lines
2.0 KiB
HTML
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<title>DOAB Link Checking for {{ publisher }}</title>
|
|
|
|
{% include "basestyle.html" %}
|
|
<style>
|
|
.itemtitle {
|
|
padding-top: 1.5ex;
|
|
font-weight: bold;
|
|
}
|
|
.checked td {
|
|
padding-right: 2em
|
|
}
|
|
#summary th {
|
|
padding-right: 2em
|
|
}
|
|
</style>
|
|
</head>
|
|
<body>
|
|
{% include "header.html" %}
|
|
<main class="section oapen-topic oapen-main">
|
|
<div class="container">
|
|
<div class="content">
|
|
<h2>
|
|
DOAB Linkchecking for
|
|
{{ publisher|default:'*** no publisher name ***' }} ({{ count|default:0 }} links)
|
|
</h2>
|
|
|
|
<h3>Link checking summary</h3>
|
|
<table id="summary">
|
|
<tr>
|
|
<th>HTTP Status Code</th>
|
|
<th>number of links</th>
|
|
<th></th>
|
|
</tr>
|
|
{% for codeobj in codes %}
|
|
{% with code=codeobj.recent_check__return_code %}
|
|
<tr {% if code != 200 %} style="color:red"{% endif %}>
|
|
<td> {{ code }} </td>
|
|
<td> <a href="#code{{ code }}">{% if codeobj.count < 998 %}{{ codeobj.count }}
|
|
{% else %} more than 1000 {% endif %}</a> </td>
|
|
<td> <a href='{{ code }}'>?</a> </td>
|
|
</tr>
|
|
{% endwith %}
|
|
{% empty %}
|
|
<tr><td colspan=2>None of the active links for {{ publisher.publisher }} have been checked.</td>
|
|
{% endfor %}
|
|
</table>
|
|
|
|
<h3>Checked links by status</h3>
|
|
<ul>
|
|
{% for codeobj in codes %}
|
|
{% with code=codeobj.recent_check__return_code %}
|
|
<h3{% if code != 200 %} style="color:red"{% endif %} id="code{{ code }}"> {{ code }}</h3>
|
|
{% for link in codeobj.links %}
|
|
{% with title=link.items.all.0.title %}
|
|
{% ifchanged title %}<div class='itemtitle'>{{ title }}</div>{% endifchanged %}
|
|
|
|
<div class='itemlink'><a href="{{ link.url }}">{{ link.url }}</a></div>
|
|
<a href="{% url 'link' link.id %}">[full info]</a>
|
|
|
|
<table class="checked">
|
|
<tr>
|
|
<td>Last checked: {{ link.recent_check.created }}</td>
|
|
<td {%if code != 200 %} style="color:red"{% endif %}>{{ code }}</td>
|
|
<td>{{ link.recent_check.content_type }}</td>
|
|
</tr>
|
|
</table>
|
|
|
|
{% if forloop.counter == 1000 %} Can't display more than 1000 links {% endif %}
|
|
{% endwith %}
|
|
{% endfor %}
|
|
|
|
{% endwith %}
|
|
{% endfor %}
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
</body>
|
|
</html> |