Mark Posts as Best Answer [Deleted]

@Lior
user profiles in my forum are showing many posts as best answer when nobody has marked them. more, they belong to a forum where the post answer feature is disabled.
 
@Lior You should add an option for enable/disable notifications personally (on alert preefences page) when a post marked as best answer.
 
@Lior. there is a bug. If you have one of your posts previously marked as best answer in a thread and someone replies to the thread at some point later, you get an alert saying that someone marked your post as best answer. This is when you're not necessarily watching the thread, either.
So if 30 people reply in a thread in which you have had a post marked as best answer, you get 30 alerts telling you someone marked your post as best answer.
Did I explain that well enough?
 
  • Like
Reactions: rdn
@Lior. there is a bug. If you have one of your posts previously marked as best answer in a thread and someone replies to the thread at some point later, you get an alert saying that someone marked your post as best answer. This is when you're not necessarily watching the thread, either.
So if 30 people reply in a thread in which you have had a post marked as best answer, you get 30 alerts telling you someone marked your post as best answer.
Did I explain that well enough?
Happens on my forum also.
 
Lior. updated Mark Posts as Best Answer with a new update entry:

Fixes and Improvements

v1.6.0 introduces the following changes:
  • In the best answers list under the first post, answers can now be previewed by hovering over the link to the post.
  • It is now possible to choose where the "mark as best answer" button would be located in posts: either in the public controls or in the private controls.
  • The thread rebuild error that occurred in threads where a deleted post had previously received a vote is now fixed.
  • A bug which caused multiple alerts to users whose...

Read the rest of this update entry...
 
Using Chris D installer/upgrade addon.

I got this error:
Callback BestAnswer_Listener::template_hook is invalid (Invalid Method).
 
Any answer???
Will contact you via a PC.

@Lior.

How do I upgrade? All I see is the "Buy Now" button, but I've already purchased it.
Please check the email address you used to purchase the add-on, I've sent an email to all of the users.

Also, you can use the link you received when you purchased the add-on, it always contains the latest version.

@Lior, is it compatible with Sticky First Post add-on now?
I'm afraid the add-ons aren't compatible and I don't really see how they can be made compatible in xF1.

Let me know if you'd like a refund.
 
Sticky first post 1.2.2+best answer=work perfect! Case not in best answer, but case in first post! Need fix some code in file /library/StickyFirstPost/Model/post.php ;)
This is original code:
PHP:
$joinOptions['joinTables'] = '
                    LEFT JOIN xf_thread AS thread ON
                        (thread.thread_id = post.thread_id AND thread.post_sticky = 1)'.$joinOptions['joinTables'];
    
        //Extended the WHERE clause to include our first post
        return $this->fetchAllKeyed('
            SELECT post.*
                ' . $joinOptions['selectFields'] . '
            FROM xf_post AS post
                ' . $joinOptions['joinTables'] . '
            WHERE post.thread_id = ?
                AND (((' . $stateLimit . ')
                ' . $this->addPositionLimit('post', $limitOptions['limit'], $limitOptions['offset']) . ') OR (post.post_id = thread.first_post_id AND thread.post_sticky))
            ORDER BY post.position ASC, post.post_date ASC

and little fix:
PHP:
$joinOptions['joinTables'] = '
                    LEFT JOIN xf_thread AS thread_sfp ON
                        (thread_sfp.thread_id = post.thread_id AND thread_sfp.post_sticky = 1)'.$joinOptions['joinTables'];
     
        //Extended the WHERE clause to include our first post
        return $this->fetchAllKeyed('
            SELECT post.*
                ' . $joinOptions['selectFields'] . '
            FROM xf_post AS post
                ' . $joinOptions['joinTables'] . '
            WHERE post.thread_id = ?
                AND (((' . $stateLimit . ')
                ' . $this->addPositionLimit('post', $limitOptions['limit'], $limitOptions['offset']) . ') OR (post.post_id = thread_sfp.first_post_id AND thread_sfp.post_sticky))
            ORDER BY post.position ASC, post.post_date ASC
 
Last edited:
@Lior.
For preventing spam voting, could you please add maximum times a member of particular usergroup can vote in a day ? (usergroup permission-based)

thx:)
 
Hello @Lior.

I wonder if you could help me please.

How are you adding the anchor to the best answer? The reason being, I have a fixed header, so when the best answer is linked to via the "Best answer list" which appears under the first post, the top portion of the best answer post is hidden behind the header.

Ideally, I need to make so that the anchor has a margin so that I can "push" the post down to allow for my header.

Hope that makes sense :)

Thank you

Richard

**EDIT**

I found a solution that works, I added this to the xenforo.css template

Code:
:target:before
{
  content:"";
  display:block;
  height:60px; /* fixed header height with 20px extra to allow a margin*/
  margin:-40px 0 0; /*header height*/
}
 
Last edited:
Hello @Lior.

I wonder if you could help me please.

How are you adding the anchor to the best answer? The reason being, I have a fixed header, so when the best answer is linked to via the "Best answer list" which appears under the first post, the top portion of the best answer post is hidden behind the header.

Ideally, I need to make so that the anchor has a margin so that I can "push" the post down to allow for my header.

Hope that makes sense :)

Thank you

Richard
Please send me a link to a thread on your forum which demonstrates the issue via a PC.
 
@Lior I have just installed this add on and it seems to do nothing :(

Settings

upload_2015-4-5_8-35-56.webp
upload_2015-4-5_8-36-19.webp

Permissions

User Permissions
upload_2015-4-5_8-37-25.webp

Moderator Permissions
upload_2015-4-5_8-38-3.webp

The Thread

upload_2015-4-5_8-39-54.webp
 
Last edited:
Top Bottom