Bug tracker

This ticket has been moved to our new tracker. Open Ticket PHPBB3-7576 now.

Pagination generates different URLs for the same topics (fix completed in vcs)

For a demonstration, I will say that I am viewing topic 1 in forum 2.

Pagination for forums works fine, but pagination for topics does not.

If I view the pagination for this topic from viewforum.php?f=2, I see these URLs:

./viewtopic.php?f=2&t=1&start=0
./viewtopic.php?f=2&t=1&start=40
./viewtopic.php?f=2&t=1&start=80
./viewtopic.php?f=2&t=1&start=120
./viewtopic.php?f=2&t=1&start=160

If I am within the topic and I view its pagination, I see these URLs(which point to the same pages):

./viewtopic.php?f=2&t=1&st=0&sk=t&sd=a
./viewtopic.php?f=2&t=1&st=0&sk=t&sd=a&start=40
./viewtopic.php?f=2&t=1&st=0&sk=t&sd=a&start=80
./viewtopic.php?f=2&t=1&st=0&sk=t&sd=a&start=120
./viewtopic.php?f=2&t=1&st=0&sk=t&sd=a&start=160

Search engines view these URLs as pointing to *different pages*, and it wastes search engines' time (because it makes them index the same content) and makes phpbb boards more difficult to search.

It would make more sense if the t, st, sk and sd variables were included in the pagination links for the topics displayed from viewforum.php.

Comments / History

Posted by Acyd Burn (Server Manager) on Jul 25th 2008, 13:53

I would say... the other way around. Omit them if they have the default value (else they need to be there).

Posted by kinabrew on Jul 25th 2008, 14:37

If they are included, then the content at the url will be basically static. If they are omitted, then a search engine might index a page and said page's content might change.

Regarding ./viewtopic.php?f=2&t=1&st=0&sk=t&sd=a&start=40

The content at this url will be basically the same regardless of whether an administrator has changed the default sort order, default number of days worth of posts displayed or number of posts per page. If the posts per page are changed, it will just lead to more content being added at the bottom of the page, but the page will be basically what a search engine has already indexed.

With this url: ./viewtopic.php?f=2&t=1&start=40

The content and order of content might change depending on if the default sort order is changed. If the page was indexed yesterday when posts were by default displayed from oldest to newest, and if today posts are now displayed from newest to oldest, the page's content and order will be different.

I wrote a script to automatically generate a sitemap and submit it to google every day, and omitting the variables seems like it will lead to more work by Google and less effective indexing.

Posted by kinabrew on Jul 25th 2008, 14:57

What would be even better is if they were omitted unless the viewer was a bot.

Posted by igorw (Development Team Member) on Jul 27th 2008, 12:32

I agree with Acyd Burn, think the "unneeded" arguments should be omnited for users. About adding them for bots, i think it should not be added. The content may change, but i think reindexing the posts is less of a problem than duplicate content.

Posted by IPB_Refugee on Jul 29th 2008, 18:32

@kinabrew:

Maybe you'd like the No Duplicate MOD and Zero Duplicate MOD from phpbb-seo.com

Regards
Wolfgang

Assigned ticket to user "Kellanved"

Action performed by Kellanved (Former Team Member) on Jul 31st 2008, 11:35

Assigned ticket to user "Acyd Burn"

Action performed by Kellanved (Former Team Member) on Jul 31st 2008, 13:23

Linked ticket with changeset: r8751

Action performed by Kellanved (Former Team Member) on Aug 13th 2008, 14:37

Linked ticket with changeset: r8752

Action performed by Kellanved (Former Team Member) on Aug 13th 2008, 14:37

Changed ticket status from "New" to "Fix completed in SVN"

Action performed by Kellanved (Former Team Member) on Aug 13th 2008, 14:43

Assigned ticket to user "Kellanved"

Action performed by Kellanved (Former Team Member) on Aug 13th 2008, 14:44

Ticket details

Related SVN changesets