shmideo Posted November 21, 2014 Share Posted November 21, 2014 Is it possible to have a link at the top of a page that has been displayed from a database? Just that some results show thousands of rows. Thanks. Quote Link to comment Share on other sites More sharing options...
QuickOldCar Posted November 21, 2014 Share Posted November 21, 2014 Sounds like you are wanting pagination or to limit the results. Here is an older pagination tutorial that uses the deprecated mysql_* functions http://www.phpfreaks.com/tutorial/basic-pagination If you just need to limit some results can add this to the end of the query shows one result LIMIT 1 starting row zero and show one result LIMIT 0,1 starting row zero and show five results LIMIT 0,5 starting row ten and show ten results LIMIT 10,10 Quote Link to comment Share on other sites More sharing options...
shmideo Posted November 21, 2014 Author Share Posted November 21, 2014 Thanks. I don't want to limit results, just the ability to jump right to the end if needed. Quote Link to comment Share on other sites More sharing options...
Solution Ch0cu3r Posted November 21, 2014 Solution Share Posted November 21, 2014 (edited) So you want to let a user jump to bottom of the page by clicking the link? No need for PHP just use a named anchor tag example <a href="#bottom">Jump to bottom</a> <!-- link to named anchor tag called bottom --> <?php // just to fill out the page with dummy data for($i = 0; $i < 100000; $i++) { echo "$i<br />"; } ?> <a name="bottom"></a> <!-- named anchor tag called bottom --> Edited November 21, 2014 by Ch0cu3r 1 Quote Link to comment Share on other sites More sharing options...
shmideo Posted November 21, 2014 Author Share Posted November 21, 2014 Ah yes! Been so wrapped up in PHP that I forgot about doing this in html. Thank you so much. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.