Browse Source

Optionally show page navigation bar at the top too.

pull/40/head
Michael Foster 11 years ago
parent
commit
c4a6116722
  1. 6
      inc/config.php
  2. 4
      stylesheets/style.css
  3. 22
      templates/index.html

6
inc/config.php

@ -797,6 +797,12 @@
// Whether or not to put brackets around the whole board list // Whether or not to put brackets around the whole board list
$config['boardlist_wrap_bracket'] = true; $config['boardlist_wrap_bracket'] = true;
// Show page navigation links at the top as well.
$config['page_nav_top'] = false;
// Show "Catalog" link in page navigation. Use with the Catalog theme.
// $config['catalog_link'] = 'catalog.html';
// Board categories. Only used in the "Categories" theme. // Board categories. Only used in the "Categories" theme.
// $config['categories'] = array( // $config['categories'] = array(
// 'Group Name' => array('a', 'b', 'c'), // 'Group Name' => array('a', 'b', 'c'),

4
stylesheets/style.css

@ -319,6 +319,10 @@ div.pages {
border-right: 1px solid #B7C5D9; border-right: 1px solid #B7C5D9;
border-bottom: 1px solid #B7C5D9; border-bottom: 1px solid #B7C5D9;
} }
div.pages.top {
display: inline-block;
padding: 4px 8px;
}
div.pages a.selected { div.pages a.selected {
color: black; color: black;
font-weight: bolder; font-weight: bolder;

22
templates/index.html

@ -25,6 +25,17 @@
{% include 'post_form.html' %} {% include 'post_form.html' %}
{% if config.page_nav_top %}
<div class="pages top">
{% for page in pages %}
[<a {% if page.selected %}class="selected"{% endif %}{% if not page.selected %}href="{{ page.link }}"{% endif %}>{{ page.num }}</a>]{% if loop.last %} {% endif %}
{% endfor %} {{ btn.next }}
{% if config.catalog_link %}
| <a href="{{ config.root }}{{ board.dir }}{{ config.catalog_link }}">Catalog</a>
{% endif %}
</div>
{% endif %}
{% if config.global_message %}<hr /><div class="blotter">{{ config.global_message }}</div>{% endif %} {% if config.global_message %}<hr /><div class="blotter">{{ config.global_message }}</div>{% endif %}
<hr /> <hr />
<form name="postcontrols" action="{{ config.post_url }}" method="post"> <form name="postcontrols" action="{{ config.post_url }}" method="post">
@ -33,9 +44,16 @@
{{ body }} {{ body }}
{% include 'report_delete.html' %} {% include 'report_delete.html' %}
</form> </form>
<div class="pages">{{ btn.prev }} {% for page in pages %}
<div class="pages">
{{ btn.prev }} {% for page in pages %}
[<a {% if page.selected %}class="selected"{% endif %}{% if not page.selected %}href="{{ page.link }}"{% endif %}>{{ page.num }}</a>]{% if loop.last %} {% endif %} [<a {% if page.selected %}class="selected"{% endif %}{% if not page.selected %}href="{{ page.link }}"{% endif %}>{{ page.num }}</a>]{% if loop.last %} {% endif %}
{% endfor %} {{ btn.next }}</div> {% endfor %} {{ btn.next }}
{% if config.catalog_link %}
| <a href="{{ config.root }}{{ board.dir }}{{ config.catalog_link }}">Catalog</a>
{% endif %}
</div>
{{ boardlist.bottom }} {{ boardlist.bottom }}
<footer> <footer>
<p class="unimportant" style="margin-top:20px;text-align:center;">Powered by <a href="http://tinyboard.org/">Tinyboard</a> {{ config.version }} | <a href="http://tinyboard.org/">Tinyboard</a> Copyright &copy; 2010-2013 Tinyboard Development Group</p> <p class="unimportant" style="margin-top:20px;text-align:center;">Powered by <a href="http://tinyboard.org/">Tinyboard</a> {{ config.version }} | <a href="http://tinyboard.org/">Tinyboard</a> Copyright &copy; 2010-2013 Tinyboard Development Group</p>

Loading…
Cancel
Save