XF 2.0 Unable to access post pages within a thread.

Darcness

Member
Any time I attempt to access posts beyond the first page, I receive a 303 redirect back to the thread main. For example, if I go to any 'page' off of a thread (http://example.com/forum/index.php?threads/my-test-thread.356/page-2) I get a 303 error and am redirected back to the main thread (http://example.com/forum/index.php?threads/my-test-thread.356/). This happens even for threads with hundreds of posts (which would definitely have a 'page 2'). It happens when I click the 'Next' button or select any page number in the page list at the top as well.

Additional information:
  • XenForo 2.0.9
  • No installed Addons
  • No outdated templates
  • No Custom styles
  • The issue is experienced by all users.
  • This behavior occurs with no browser add-ons installed (Incognito Mode in Chrome)
  • No errors appear in the ACP Error log
  • I am unable to reproduce the problem here on the XenForo.com
 
Code:
#       Mod_security can interfere with uploading of content such as attachments. If you
#       cannot attach files, remove the "#" from the lines below.
#<IfModule mod_security.c>
#       SecFilterEngine Off
#       SecFilterScanPOST Off
#</IfModule>

ErrorDocument 401 default
ErrorDocument 403 default
ErrorDocument 404 default
ErrorDocument 405 default
ErrorDocument 406 default
ErrorDocument 500 default
ErrorDocument 501 default
ErrorDocument 503 default

<IfModule mod_rewrite.c>
        RewriteEngine Off

        #       If you are having problems with the rewrite rules, remove the "#" from the
        #       line that begins "RewriteBase" below. You will also have to change the path
        #       of the rewrite to reflect the path to your XenForo installation.
        #RewriteBase /forum

        RewriteCond %{REQUEST_FILENAME} -f [OR]
        RewriteCond %{REQUEST_FILENAME} -l [OR]
        RewriteCond %{REQUEST_FILENAME} -d
        RewriteRule ^.*$ - [NC,L]
        RewriteRule ^(data/|js/|styles/|install/|favicon\.ico|crossdomain\.xml|robots\.txt) - [NC,L]
        RewriteRule ^.*$ index.php [NC,L]
</IfModule>

I tried changing the RewriteEngine to 'On' and it didn't help.
 
Found the problem. There was some database corruption that caused the position column in xf_post to end up all 0's, so the Thread controller kept thinking that we were trying to view the first post no matter what page we were trying to access. Manually fixing the data repaired the issue.
 
Top Bottom