My customer has a special requirement on reply sorting in a forum topic. We implemented a ‘mark as answer’ feature to mark a reply as the answer of the topic. This information is stored in postmeta table. Now we want to sort the replies in the topic in this order:
– The original post appears at the first place.
– The ‘marked as answer’ reply is in second place.
– The remaining replies are sorted by date as normal.