Skip to:
Content
Pages
Categories
Search
Top
Bottom

how to fix old topic moving to first topic when a reply is made


  • kent25
    Participant

    @kent25

    Am really new to bbpress, How do i fix an old topic becoming a first topic when a member makes a reply on it?

    i my forum, there are different topics made by members, on daily bases but i found out that when a new member replies to an old topic, that topic automatically moves to the top of other new topics…
    this is a pain. pls is there a code to stop this, i don’t need plugins for it.

Viewing 5 replies - 1 through 5 (of 5 total)

  • Barry
    Participant

    @barryhughes-1

    I imagine somewhere in these forums there must be an example of code that will help with this, though my own initial search let me down. Even so, it’s certainly possible to do and here is a minimal example of the sort of code you could use:

    https://gist.github.com/barryhughes/1d52e7562e5d2e6f5121981a4babdd36

    To meet your individual needs it may need refinement or adjustment (every site is different, there could be factors for you, locally, that I don’t know about). It’s just a starting point.

    For those who might be tempted to use this but are unfamiliar with code in general, note that if you do copy this code to an existing file, such as your theme’s functions.php file, then you don’t need to copy the opening “<?php” tag—just place it somewhere after the existing tag in whichever file you are editing.

    @kent25
    The basic reasoning of a forum is: When a topic gets a reply, then the topic has changed so it will show first because the default ordering is by ‘topic last activity’.
    It did not test what @barryhughes-1 wrote, but the reasoning looks to be correct for keeping them shown in the order of topic creation date (not modification)


    kent25
    Participant

    @kent25

    so was the use of a search bar @casiepa


    kent25
    Participant

    @kent25

    @barryhughes-1 Thanks Boss, it worked so well……..
    your the MAN.

    do you have any code for voting?


    Robin W
    Moderator

    @robin-w

    great – glad you are fixed

Viewing 5 replies - 1 through 5 (of 5 total)
  • You must be logged in to reply to this topic.
Skip to toolbar