aboutsummaryrefslogtreecommitdiff
path: root/templates/results.html
diff options
context:
space:
mode:
Diffstat (limited to 'templates/results.html')
-rw-r--r--templates/results.html39
1 files changed, 36 insertions, 3 deletions
diff --git a/templates/results.html b/templates/results.html
index 759213b..1bda9e4 100644
--- a/templates/results.html
+++ b/templates/results.html
@@ -54,11 +54,44 @@
<nav class="pagination">
<a class="pagination-btn prev" href="/search?q={{query}}&p={{prev_page}}">
- &larr; Page {{prev_page}}
+ &larr;
</a>
- <span class="pagination-current">Page {{page}}</span>
+
+ {{if two_prev_page != 0}}
+ <a class="pagination-btn prev" href="/search?q={{query}}&p={{two_prev_page}}">
+ {{two_prev_page}}
+ </a>
+ {{endif}}
+
+ {{if prev_page != 0}}
+ <a class="pagination-btn prev" href="/search?q={{query}}&p={{prev_page}}">
+ {{prev_page}}
+ </a>
+ {{endif}}
+
+ <a class="pagination-current" href="/search?q={{query}}&p={{page}}">
+ {{page}}
+ </a>
+ <a class="pagination-btn next" href="/search?q={{query}}&p={{next_page}}">
+ {{next_page}}
+ </a>
+ <a class="pagination-btn next" href="/search?q={{query}}&p={{two_next_page}}">
+ {{two_next_page}}
+ </a>
+
+ {{if prev_page == 0}}
+ <a class="pagination-btn prev" href="/search?q={{query}}&p=4">
+ 4
+ </a>
+ {{endif}}
+
+ {{if two_prev_page == 0}}
+ <a class="pagination-btn prev" href="/search?q={{query}}&p=5">
+ 5
+ </a>
+ {{endif}}
<a class="pagination-btn next" href="/search?q={{query}}&p={{next_page}}">
- Page {{next_page}} &rarr;
+ &rarr;
</a>
</nav>
</main>