[RFC] Auto-load additional content on scrolling to end

Note: We are moving the topics of this forum and it will be deleted at some point

Publish your own request for comments/change or patches for the next version of phpBB. Discuss the contributions and proposals of others. Upcoming releases are 3.2/Rhea and 3.3.
User avatar
imkingdavid
Registered User
Posts: 1050
Joined: Thu Jul 30, 2009 12:06 pm

Re: [RFC] Auto-load additional content on scrolling to end

Post by imkingdavid »

brunoais wrote:About this subject I have the following to say (note: some stuff may be repetitive to what has been told, I'll try not to repeat):

I like this idea, I agree it should be an option in the UCP and in the ACP.
The options for both ACP(forum specific option perhaps... One forum has infinite scrolling and other not) and UCP should consist in:
(Always/Press To Load/No) infinite down scrolling
(Int) Max number of posts in page. This number must be >=3 where any other number means infinite (translated to 0?) (ignored if upper option is N)
Extra: Should we differentiate anonymous from the registered users?
Yes, both ACP (per forum) and UCP (global) should provide an option to enable/disable (of course the user option is dependent on the admin option). There is already a posts per page setting in ACP, I'm not sure we would need to add another into the UCP (unless there already is one that I'm missing).
The next posts should load when the user is viewing the last post (or the post before that), not when reaches the end of the page.
Right. Perhaps a nice "Loading..." animation could be displayed at a certain point while the posts are loaded. And of course, this would apply at the top of the "page" as well for loading previous posts.
This can actually be also a good idea. Something below, near the bottom of the screen
I don't really know how to implement that using jQuery but I do know that is possible I don't know if it's with divs. Anyway, Js does not care about the CSS, for the js, visibility:hidden or display:none or display:block, etc... are all the same. As long as the node is in the DOM it's treated the same way.
We should also alter the url as the user scrolls the page.
I have not looked into this since I posted this, but may do so before too long if no one else does.
This ?f=108&t=42113#p231603 identifies a post in the page and then, as the pages change, it becomes this: ?f=108&t=42113#page=3. The user can use the back and forward of his browser to navigate between all loaded pages. Also, with this, he can use the link in the title of the post to jump between two different posts in the same page (if they are both loaded at the same time)
Something like that might be a good idea.
This should apply to all pages where pagination and scrolling exists (as stated in the OP post).
Agreed.
imkingdavid wrote: Edit: Alternatively, we could have the footer in a fixed div or semi-fixed div (aka fixed after a certain point on the page, like in the Bug Tracker) so that it can still be accessed even when more posts are loaded behind/below it. Does that make sense?
Yep, a lot. But I believe I have a better one:
Make The page footer with that concept of smi-fixed with an arrow to make it hide. Make a small icon for an arrow or an 'x' or these: "«" in a vertical way. This way we can navigate though the page with no cutting from the top or the bottom, open the footer to view it when we want. I believe that is the best option. Make a cookie to save whether it should be opened or closed by default (checkbox in the footer?)
I think it should start out closed with a little up arrow or something (which changes to down when you click it) to display the footer on top of the post at the bottom. EDIT: Really, the only link I ever use in the footer is the ACP link (who clicks the phpBB link, anyway? :lol:). Perhaps moving that up on the same line as the User Control Panel link would be a good idea? But that would of course be another RFC.
I do custom MODs. PM for a quote!
View My: MODs | Portfolio
Please do NOT contact for support via PM or email.
Remember, the enemy's gate is down.

User avatar
brunoais
Registered User
Posts: 964
Joined: Fri Dec 18, 2009 3:55 pm

Re: [RFC] Auto-load additional content on scrolling to end

Post by brunoais »

imkingdavid wrote:
brunoais wrote:About this subject I have the following to say (note: some stuff may be repetitive to what has been told, I'll try not to repeat):

I like this idea, I agree it should be an option in the UCP and in the ACP.
The options for both ACP(forum specific option perhaps... One forum has infinite scrolling and other not) and UCP should consist in:
(Always/Press To Load/No) infinite down scrolling
(Int) Max number of posts in page. This number must be >=3 where any other number means infinite (translated to 0?) (ignored if upper option is N)
Extra: Should we differentiate anonymous from the registered users?
Yes, both ACP (per forum) and UCP (global) should provide an option to enable/disable (of course the user option is dependent on the admin option). There is already a posts per page setting in ACP, I'm not sure we would need to add another into the UCP (unless there already is one that I'm missing).
Well.... I have a number of posts per page I want when it tries to load all at the same time. The reason is because it's CPU or internet heavy and not memory or content heavy (less amount loaded at the same time means faster loading and processing of the page).
Minimizing the number of the posts initially loaded increases the speed the page is loaded, minimizing the amount of posts that are loaded for every AJAX query decreases (speeds up) the time used to display the next posts. On the other hand, if I have a very small amount of posts loaded at start and then allow lots of posts available in the current page, I can optimize the internet traffic and CPU usage. If I set the number of posts to a small number I'll use a lot of bandwidth for a little scroll just because I wanted to have a little amount of posts initially and load the rest as I was scrolling.
Got it ;) ?
imkingdavid wrote:
The next posts should load when the user is viewing the last post (or the post before that), not when reaches the end of the page.
Right. Perhaps a nice "Loading..." animation could be displayed at a certain point while the posts are loaded. And of course, this would apply at the top of the "page" as well for loading previous posts.
+1
imkingdavid wrote:
This can actually be also a good idea. Something below, near the bottom of the screen
I don't really know how to implement that using jQuery but I do know that is possible I don't know if it's with divs. Anyway, Js does not care about the CSS, for the js, visibility:hidden or display:none or display:block, etc... are all the same. As long as the node is in the DOM it's treated the same way.
We should also alter the url as the user scrolls the page.
I have not looked into this since I posted this, but may do so before too long if no one else does.
I'll see what I can do. If some1 is doing that job pls warn me. I want to help in phpbb project but I think parallel working in the same thing does not make sense unless it's critical code.
imkingdavid wrote:
This ?f=108&t=42113#p231603 identifies a post in the page and then, as the pages change, it becomes this: ?f=108&t=42113#page=3. The user can use the back and forward of his browser to navigate between all loaded pages. Also, with this, he can use the link in the title of the post to jump between two different posts in the same page (if they are both loaded at the same time)
Something like that might be a good idea.

User avatar
brunoais
Registered User
Posts: 964
Joined: Fri Dec 18, 2009 3:55 pm

Re: [RFC] Auto-load additional content on scrolling to end

Post by brunoais »

How is this goin'?

User avatar
callumacrae
Former Team Member
Posts: 1046
Joined: Tue Apr 27, 2010 9:37 am
Location: England
Contact:

Re: [RFC] Auto-load additional content on scrolling to end

Post by callumacrae »

brunoais wrote:How is this goin'?
It's not. It's 3.2. :-)
Made by developers, for developers!
My blog

Jocelyn79
Registered User
Posts: 11
Joined: Mon Apr 04, 2011 12:42 pm

Re: [RFC] Auto-load additional content on scrolling to end

Post by Jocelyn79 »

OK to add more AJAX to phpbb, but only if it makes things easier or nicer for the user.
I've seen this system on several websites, and I really dislike it.

When I go to multi-page topic, I immediately open the next page in a second tab. When I'm finished reading the first page, I close the first tab (or switch to the second tab) and immediately open the third page in another tab.
Therefore, I never have to wait when I read a long topic.

I'd prefer to keep the pagination as it is.
As long as a it's possible to switch it off in the admin panel, I'll be fine.

Where's the OFF switch? :mrgreen: :twisted:

User avatar
callumacrae
Former Team Member
Posts: 1046
Joined: Tue Apr 27, 2010 9:37 am
Location: England
Contact:

Re: [RFC] Auto-load additional content on scrolling to end

Post by callumacrae »

Jocelyn79 wrote:When I go to multi-page topic, I immediately open the next page in a second tab. When I'm finished reading the first page, I close the first tab (or switch to the second tab) and immediately open the third page in another tab.
Therefore, I never have to wait when I read a long topic.
That can be really easily solved by simply loading a page either side when the user views a page :-)
Made by developers, for developers!
My blog

Jocelyn79
Registered User
Posts: 11
Joined: Mon Apr 04, 2011 12:42 pm

Re: [RFC] Auto-load additional content on scrolling to end

Post by Jocelyn79 »

callumacrae,
my previous post was not explaining a problem, but giving a solution in reply to the first post in this discussion, that says (among other things):
DavidIQ wrote: Why would you want that?
  • Improves the reading flow when reading a topic.
  • Reduces wait time.
In my previous post I was explaining that by loading the next page in a new tab, I never have to wait. So, an AJAX thing to preload contents seems useless to me.

ecwpa
Registered User
Posts: 181
Joined: Mon Jan 24, 2005 2:10 am
Contact:

Re: [RFC] Auto-load additional content on scrolling to end

Post by ecwpa »

I think the RFC proposal is better than your method because I could still read previously readed comments since I'm still on the same page, it may save bandwith by loading just new post instead of everything including overall_header and overal_footer and it's just a more natural way to read something, you don't even have to click on anything, close tabs, etc.

I'm sure you're not expecting every user to browse a forum the way you do because they don't so, making it easier for everybody is always something to consider.
Slightly better English than it was in 2005, still improving :D

Post Reply