a problem in topic page numbers

Discussions about the phpBB2 Forum. How to get the best from this powerful script.

Moderator: Moderators

a problem in topic page numbers

Postby AmirAbbas » Fri Sep 29, 2006 6:22 am

hi

another problem
plesee see this page

http://forum.persia-cms.com/forum-vf22.html

there is a post with this title in this URL

چه سیستمی بهتر است؟

this topic has 20 post
i set to show 10 post in each page
as you can see under this topic there is number 1,2,3
when you click on number 3 you will see this message

هيچ نامه اي براي اين موضوع ارسال نشده است.
that means "there isn,t any post for this topic

this topic must have only 2 page because has only 20 post
:!:
i have this problem with few other topics
User avatar
AmirAbbas
phpBB SEO Team
phpBB SEO Team
 
Posts: 534
Joined: Thu May 11, 2006 3:30 pm
Location: IRAN

Advertisement

Postby dcz » Fri Sep 29, 2006 8:58 pm

mmmh, strange, and I don't see how it could be related to mod rewrite as it's ore than link transformation, it's link creation.

Does it occur for all topics, only page three, etc ... this forum of yours only ?

Could be SQL cache, try clearing it ?

What's happening if you set pagination to 15 posts per pages in a topic with 30 posts ?

++
Useful links :
SEO Forum || SEO Directory || SEO phpBB || Search
____________________

Liens Utiles :
Forum référencement || Annuaire référencement || Référencement phpBB || Recherche
dcz
Admin
Admin
 
Posts: 21428
Joined: Fri Apr 28, 2006 9:03 pm

Postby gowap » Sun Oct 01, 2006 12:28 am

I've the same problem on my board but fortunately just with one topic. It's a quite long one (53 pages) and the symptoms are the one you described : a new page number appears and when you click on it, it says there's no page number xx (or when you click on the last topic icon, it says there's no such topic). Very stange. But this has nothing to do with rewriting (i had the problem before i implemented any rewriting solution).

I didn't searched about this issue, after all it's only one topic, and to "solve" it i just make a new post and everything gets ok
Gravure-News : la communauté francophone de la gravure de CD/DVD et son forum d'entraide.
User avatar
gowap
phpBB SEO Team
phpBB SEO Team
 
Posts: 1510
Joined: Sun May 07, 2006 10:56 pm

Postby gowap » Sun Oct 01, 2006 1:22 am

Well, i thought it was time to investigate this matter. For sure this has to do with database inconsistency.
So i first looked at the topics table :
Code: Select all
SELECT topic_replies
FROM `phpbb_topics`
WHERE topic_id =2280

This gave me : 1057
Now we check if we have the same data in the phpbb_posts table :

Code: Select all
SELECT *
FROM `phpbb_posts`
WHERE topic_id =2280

This one gave me 1058 results.
So far all is OK : 1058 posts = 1 post (the initial one) and the 1057 replies (as stated in the topics table)

So the inconsistency must be in the post_text table.
the following query checks if there is a post text (in phpbb_posts_text) for every post referenced in phpbb_posts for the specified topic.
If not it will output the post_id which has no entry in posts_text :
Code: Select all
SELECT phpbb_posts.post_id, phpbb_posts_text.post_id
FROM `phpbb_posts`
LEFT JOIN phpbb_posts_text ON phpbb_posts.post_id = phpbb_posts_text.post_id
WHERE topic_id =2280
AND phpbb_posts_text.post_id IS NULL

guess what, the query told me that post_id=75583 had no text defined.
So I kicked the post_id=75583 from the phpbb_posts table and changed the topic_replies to 1056 in phpbb_topics and everything runs smooth now.

By the way, such inconsistencies (and many others) can be checked through the entire database with some MODS. For now i only remember one (good one) : database maintenance ( see http://phpbb.kordowich.net/?pgid=8 ). The only "drawback" (when i tested a long time ago) is that there was no "report only" option. You launch any of the "check xxx" function and changes are applied immediately/automatically without confirmation (but maybe this has changed now). Indeed, the mod is well known and tested, so you can trust it (but always backup first of course :D )
Gravure-News : la communauté francophone de la gravure de CD/DVD et son forum d'entraide.
User avatar
gowap
phpBB SEO Team
phpBB SEO Team
 
Posts: 1510
Joined: Sun May 07, 2006 10:56 pm

Postby dcz » Mon Oct 02, 2006 10:59 am

Interesting, thanks for sharing Gowap, I never experienced SQL inconsistency so far but for sure this is the kind of thing that can happen in a phpBB forum's life as well as for any other SQL application I guess.

There are quite some mod to repair phpBB table, one of these days, I'll test them ;)

++
Useful links :
SEO Forum || SEO Directory || SEO phpBB || Search
____________________

Liens Utiles :
Forum référencement || Annuaire référencement || Référencement phpBB || Recherche
dcz
Admin
Admin
 
Posts: 21428
Joined: Fri Apr 28, 2006 9:03 pm

Postby AmirAbbas » Tue Oct 03, 2006 2:31 pm

thanks gowap
thanks DCZ

i will test it
User avatar
AmirAbbas
phpBB SEO Team
phpBB SEO Team
 
Posts: 534
Joined: Thu May 11, 2006 3:30 pm
Location: IRAN


Return to phpBB2 Forum

 


  • Related topics
    Replies
    Views
    Last post

Who is online

Users browsing this forum: No registered users and 2 guests