Support Forum
well, I cannot replicate any problem like that... same problem before the change, but fixed after... and the only way to get that message is if this check failed:
if (sp_get_auth('delete_any_post', $forumid) || (sp_get_auth('delete_own_posts', $forumid) && $spThisUser->ID == $poster)) {
which is a permission check and making sure the post they are deleting is their own... so please recheck the code change... and guess you could try resetting the auths cache on forum - toolbox - housekeeping...
Visit Cruise Talk Central and Mr Papa's World
Mr Papa said
well, I cannot replicate any problem like that... same problem before the change, but fixed after... and the only way to get that message is if this check failed:if (sp_get_auth('delete_any_post', $forumid) || (sp_get_auth('delete_own_posts', $forumid) && $spThisUser->ID == $poster)) {
which is a permission check and making sure the post they are deleting is their own... so please recheck the code change... and guess you could try resetting the auths cache on forum - toolbox - housekeeping...
Hi Steve,
In what file do i find above code string?
Did try to reset the auths chache, but it did not help.
as stated in post #9, its simple-press/forum/content/ahah/sp-ahah-admintoollinks.php
Visit Cruise Talk Central and Mr Papa's World
Mr Papa said
if (sp_get_auth('delete_any_post', $forumid) || (sp_get_auth('delete_own_posts', $forumid) && $spThisUser->ID == $poster)) {
Hi Steve,
My sp-ahah-admintoollinks.php looks a bit different from the code you posted above, but i am not skilled enough to judge if something is wrong or not.
if (sp_get_auth('delete_any_post', $post['forum_id']) || sp_get_auth('delete_own_posts', $forum['forum_id']) && $spThisUser->ID == $post['user_id']) {
well thats why I said AROUND line 137, find this line:
$ajaxUrl = SFHOMEURL.'index.php?sp_ahah=admintools&sfnonce='.wp_create_nonce('forum-ahah').'&action=delete-post&killpost='.$post['post_id'].'&killposttopic='.$post['topic_id'].'&killpostforum='.$post['forum_id'].'&killpostpopster='.$post['user_id'].'&page='.$page;
because of version differences... its about 4 lines of code lower than the one you referenced...
in that line, you would change killpostpopster to killpostposter
Visit Cruise Talk Central and Mr Papa's World
Mr Papa said
well thats why I said AROUND line 137, find this line:$ajaxUrl = SFHOMEURL.'index.php?sp_ahah=admintools&sfnonce='.wp_create_nonce('forum-ahah').'&action=delete-post&killpost='.$post['post_id'].'&killposttopic='.$post['topic_id'].'&killpostforum='.$post['forum_id'].'&killpostpopster='.$post['user_id'].'&page='.$page;
because of version differences... its about 4 lines of code lower than the one you referenced...
in that line, you would change killpostpopster to killpostposter
We are missunderstanding each other Steve.
I allready did change killpostpopster to killpostposter. No problem with that, except i got the permission issue as stated above.
However when you responded:
well, I cannot replicate any problem like that… same problem before the change, but fixed after… and the only way to get that message is if this check failed:
if (sp_get_auth('delete_any_post', $forumid) || (sp_get_auth('delete_own_posts', $forumid) && $spThisUser->ID == $poster)) {
I thought that you asked me to check that code string as well, which i did, but i supose i did missunderstand you?
No, I responded that if you made the change, then the only way to get the text message you related was if that auth check was failing... there was nothing to check per se in that line I pointed to as the reason for the message... and sorry, the line of code I referenced is actually in a different file (forum/database/sp-db-management.php line 630)
either the user cannot delete any post OR the user cannot delete own posts if the current post being delete is theirs...
I guess it might be good info to know which portion of that auth check is failing...
also if you could right click on the Delete this post link in the admin tools popup and inspect it to the onclick portion of the link, it would be helpful too..
but with the change, users deleting their own posts is working fine for me on multiple test sites now...
Visit Cruise Talk Central and Mr Papa's World
so you sent me some credentials... and the user only has one post... but it also does not appear that the user can delete their own posts (not offered chance to delete)
is this delete issue on different site than the subforum icon issue?
Visit Cruise Talk Central and Mr Papa's World
Mr Papa said
either the user cannot delete any post OR the user cannot delete own posts if the current post being delete is theirs...
I guess it might be good info to know which portion of that auth check is failing...
also if you could right click on the Delete this post link in the admin tools popup and inspect it to the onclick portion of the link, it would be helpful too..
but with the change, users deleting their own posts is working fine for me on multiple test sites now...
If i give the users premission to delete ALL posts, it works as intended. But if i remove that permission and they only have rights to delete their OWN, it does not work.
Hmm not sure i did what you wanted, but here is an image of admin tools popup link:
1 Guest(s)