]> ruin.nu Git - ndwebbie.git/blobdiff - root/src/rankings/planets.tt2
Don't show the Next link when we've reached the end
[ndwebbie.git] / root / src / rankings / planets.tt2
index a58ae6f0a86e14ceb466649c38a691e7678e426d..1ddf59a81512015f9fa43d022372787861837007 100644 (file)
@@ -1,6 +1,6 @@
 [% META title = 'Planet Rankings' %]
 <p>[% IF offset > 0 %]<a href="[% c.uri_for('planets', order, offset - 100) %]">Previous 100</a>[% END %]
-       <a href="[% c.uri_for('planets', order, offset + 100) %]">Next 100</a>
+       [% IF planets.size > 0 %]<a href="[% c.uri_for('planets', order, offset + 100) %]">Next 100</a>[% END %]
 </p>
 <table class="stats">
        <tr align="center"><th colspan="4">Rank</th>
@@ -55,5 +55,5 @@
 [% END %]
 </table>
 <p>[% IF offset > 0 %]<a href="[% c.uri_for('planets', order, offset - 100) %]">Previous 100</a>[% END %]
-       <a href="[% c.uri_for('planets', order, offset + 100) %]">Next 100</a>
+       [% IF planets.size > 0 %]<a href="[% c.uri_for('planets', order, offset + 100) %]">Next 100</a>[% END %]
 </p>