The Naked Scientists

The Naked Scientists Forum

Author Topic: Navigation problems on the site  (Read 5613 times)

Offline Atomic-S

  • Hero Member
  • *****
  • Posts: 935
  • Thanked: 19 times
    • View Profile
Navigation problems on the site
« on: 10/04/2007 05:52:12 »
I see one slight problem with this web site: When downloading discussions sorted in order of most recent post, the most recent are at the end, of course. Going there is easy; however if a person wants to go to the previous-to-last page, there is no way that I can find to jump back just one page; it appears that the viewer must start at the beginning and click through the whole bunch untill he or she reaches it. Very inefficient.


 

another_someone

  • Guest
Navigation problems on the site
« Reply #1 on: 10/04/2007 12:59:53 »
If you click on the last page, you will see a list of pages at the bottom of the current page (if there are too many pages to list them all, it will list two preceding and two succeeding the current page).  You can then directly select the page preceding the current page.

If there are 35 pages in a topic, it is fairly easy to get to page 2, or to get to page 34, but it is more problematic to get to page 17.
 

paul.fr

  • Guest
Navigation problems on the site
« Reply #2 on: 10/04/2007 13:17:18 »
If you click on the last page, you will see a list of pages at the bottom of the current page (if there are too many pages to list them all, it will list two preceding and two succeeding the current page).  You can then directly select the page preceding the current page.

If there are 35 pages in a topic, it is fairly easy to get to page 2, or to get to page 34, but it is more problematic to get to page 17.

Alternatevly, a long winded way to navigate to each page is as follows, say you are in the  The Naked Scientists Forum  |  General Discussion & Feedback  |  Just Chat !  |  DIARY ENTRIES & GENERAL CHAT !!!!!!! (VER 3) thread.

this has at the moment 65 pages, each page has 25 posts and the initial url for that page is: http://www.thenakedscientists.com/forum/index.php?topic=5380.0 if you want to jump to any given page change the last digits after the topic=5380.0 by a factor of 25.

so page 11 of that topic will have the url http://www.thenakedscientists.com/forum/index.php?topic=5380.250
 
 

another_someone

  • Guest
Navigation problems on the site
« Reply #3 on: 10/04/2007 13:36:20 »
each page has 25 posts

I have to say that I had not counted the posts, but are you saying that the number of posts per page does not take into account the length of each post.  I suppose it is not too easy to calculate the length of each post ahead of time, but the length of posts can vary from one liners, to some covering several hundred lines (as you found out with some of my posts :)), as well as having some large images.
 

paul.fr

  • Guest
Navigation problems on the site
« Reply #4 on: 10/04/2007 13:39:07 »
each page has 25 posts

I have to say that I had not counted the posts, but are you saying that the number of posts per page does not take into account the length of each post.  I suppose it is not too easy to calculate the length of each post ahead of time, but the length of posts can vary from one liners, to some covering several hundred lines (as you found out with some of my posts :)), as well as having some large images.

yes, i believe each topic only has 25 posts per page regardless of length. as for the other....i have the scars and nightmares  ;)

i would think the code would just have a simple, posts per page variable. in old BASIC a simple "if posts >25 then page = page+1" or something like that
« Last Edit: 10/04/2007 13:47:35 by paul.fr »
 

another_someone

  • Guest
Navigation problems on the site
« Reply #5 on: 10/04/2007 15:03:10 »
i would think the code would just have a simple, posts per page variable. in old BASIC a simple "if posts >25 then page = page+1" or something like that

I suspect it is all done using the LIMIT clause in SQL - e.g.:

SELECT ... WHERE topic = ... LIMIT page * 25, 25;

Alternatively:

SELECT ... WHERE message >= message_id AND topic = ... LIMIT 25;
« Last Edit: 10/04/2007 15:09:44 by another_someone »
 

paul.fr

  • Guest
Navigation problems on the site
« Reply #6 on: 10/04/2007 15:21:18 »
i would think the code would just have a simple, posts per page variable. in old BASIC a simple "if posts >25 then page = page+1" or something like that

I suspect it is all done using the LIMIT clause in SQL - e.g.:

SELECT ... WHERE topic = ... LIMIT page * 25, 25;

Alternatively:

SELECT ... WHERE message >= message_id AND topic = ... LIMIT 25;

most likely, i just used an old basic form as it looks simple to those who don't code.
may be dave will come along and enlighten us.
 

Offline Karen W.

  • Moderator
  • Naked Science Forum GOD!
  • *****
  • Posts: 31653
  • Thanked: 5 times
  • "come fly with me"
    • View Profile
Navigation problems on the site
« Reply #7 on: 10/04/2007 16:34:53 »
It all sounds like french to me!!!LOL

OH DEAR...This was my 9000TH POST WHERE THE H*** is SIR NEIL!!
« Last Edit: 10/04/2007 16:38:00 by Karen W. »
 

Offline tony6789

  • Neilep Level Member
  • ******
  • Posts: 1127
    • View Profile
Navigation problems on the site
« Reply #8 on: 10/04/2007 16:35:42 »
more like japanese with all the symbols
 

Offline daveshorts

  • Moderator
  • Neilep Level Member
  • *****
  • Posts: 2583
  • Physics, Experiments
    • View Profile
    • http://www.chaosscience.org.uk
Navigation problems on the site
« Reply #9 on: 24/04/2007 13:04:51 »
I would have thought it is done with a limit statement in the SQL - if you are really interested I could have a look.

Working out the lengths of the posts would be really difficult, not least because their relative length would change with the width of the screen and the text size etc.
 

The Naked Scientists Forum

Navigation problems on the site
« Reply #9 on: 24/04/2007 13:04:51 »

 

SMF 2.0.10 | SMF © 2015, Simple Machines
SMFAds for Free Forums
 
Login
Login with username, password and session length