Number of post

Started by Elisa, June 13, 2004, 04:25:09 PM

Previous topic - Next topic

Elisa

When I delete the topics, the number of the post of forum members diminish. I want that the number of post does not diminish.
Help!
(Sorry, I speak least English!)

Meriadoc

this isn't solving your problem, sorry, but if you speak one of the languages that we have in our multi-lingual support board you may find it both more comfortable and easier :) We have a very international support base. Just a thought, might be helpful :)
Merry
If I know the way home and am walking along it drunkenly, is it any less the right way because I am staggering from side to side? : Leo Tolstoy
Everything I know I learned from Calvin and Hobbes.
And patience is about the most useful thing you could ever have.  That and backups. : [Unknown]
If I choose to send thee, Tuor son of Huor, then believe not that thy one sword is not worth the sending. : Ulmo, Lord of the Waters - Unfinished Tales, by J.R.R. Tolkien

Chris Cromer

To do this you will have to modify the source code.

Open RemoveTopic.php and search for:
// Decrease the post counts.
if ($decreasePostCount)
{
$requestMembers = db_query("
SELECT m.ID_MEMBER, COUNT(m.ID_MSG) AS posts
FROM {$db_prefix}messages AS m, {$db_prefix}boards AS b
WHERE m.ID_TOPIC $condition
AND b.ID_BOARD = m.ID_BOARD
AND m.icon != 'recycled'
AND b.countPosts = 0
GROUP BY m.ID_MEMBER", __FILE__, __LINE__);


and replace that with:

// Decrease the post counts.
$decreasePostCount = false;
if ($decreasePostCount)
{
$requestMembers = db_query("
SELECT m.ID_MEMBER, COUNT(m.ID_MSG) AS posts
FROM {$db_prefix}messages AS m, {$db_prefix}boards AS b
WHERE m.ID_TOPIC $condition
AND b.ID_BOARD = m.ID_BOARD
AND m.icon != 'recycled'
AND b.countPosts = 0
GROUP BY m.ID_MEMBER", __FILE__, __LINE__);


That will stop post counts from going down when you delete topics.
Chris Cromer

"I was here, here I was, was I here, sure I was" - The little voice in my head.

Elisa


Alexandre P.

That's not of my business, but why ?  Why don't you want the post count to decrease ?
Aucun support par M.P., courriel ou messagerie instantanée / No support by P.M., email or I.M.

Cypher7

I suppose, if you were deleting posts from a good few months ago that were old, and you were doing it to keep the size down or something, then it wouldn't be fair on the posters who got their count up for those posts... but I dont think you really need to delete posts...

IMO, if you delete a post cos it's inappropriate or whatever, then the count should go down with it...

Chris Cromer

He wasn't deleting posts, he was deleting topics. When you delete topics it lowers the post count of every member that posted in that topic. He didn't want that to happen. Basically he wanted it to act the same way when deleting topics that YaBBSE did.
Chris Cromer

"I was here, here I was, was I here, sure I was" - The little voice in my head.

Anguz

didn't YaBB SE lower the post count when removing topics? I'm almost sure it did (^^;)
Cristián Lávaque http://cristianlavaque.com

Chris Cromer

No, it only lowered it when deleteing posts. Members post counts remained the same when topics where deleted.
Chris Cromer

"I was here, here I was, was I here, sure I was" - The little voice in my head.

Oldiesmann

There's an easier way to do it:

In Sources/Removetopic.php

For topics:
Find
function removeTopics($topics, $decreasePostCount = true, $ignoreRecycling = false)

Replace
function removeTopics($topics, $decreasePostCount = false, $ignoreRecycling = false)

For posts:
Find
function removeMessage($message, $decreasePostCount = true)

Replace
function removeMessage($message, $decreasePostCount = false)
Michael Eshom
Christian Metal Fans

Alexandre P.

Is it possible to have the topics / posts deletion to decrease by default the post count except on certain topics / posts (manually selected by the admins or the (global) moderators when deleting) ?  Like having a selection box next to every post title that when it is selected won't lower the poster's post count ?

As a mod, maybe ?
Aucun support par M.P., courriel ou messagerie instantanée / No support by P.M., email or I.M.

Oldiesmann

Probably wouldn't be too difficult to add as a mod.
Michael Eshom
Christian Metal Fans

Advertisement: