1.0.6
- Only use legacy thread ID meta value for old posts
get_comments_number
function and returns a reply count that is automatically updated when the comments are loaded on a post. No edits should be required to any theme built in a standard way for the plugin to work. Like I'm sure most WP plugins are, this plugin is built to be dropped in and doesn't require any theme edits to work. The comments template gets automatically swapped out and inherits the same styling of the comments for the theme, and the reply count is automatically swapped out from the internal WP comment count.Is there a longer stack trace for that? Unless the thread has been deleted or something I can't see what would be throwing a permissions error.Thought I would give this another go
Anyway, managed to connect everything fine, adding the post to Xenforo works but I am getting this error in WP when I try and view the post on the WP side:
Uncaught XFApi\Exception\RequestException\NoPermissionRequestException: You do not have permission to view this page or perform this action.
This is a similar error to the one you get when you haven't set up a user with the API permissions. Any idea why this error is happening when you simply try to view the post on WP?
[04-Jun-2022 15:05:21 UTC] PHP Fatal error: Uncaught XFApi\Exception\RequestException\NoPermissionRequestException: You do not have permissions to view this page or perform this action. in /var/www/host_user/data/www/localhost/wp-content/plugins/article-forum-connect/vendor/xfapi/xfapi-php/src/Client.php:396
Stack trace:
#0 /var/www/host_user/data/www/localhost/wp-content/plugins/article-forum-connect/vendor/xfapi/xfapi-php/src/Client.php(362): XFApi\Client->handleException(403, Array)
#1 /var/www/host_user/data/www/localhost/wp-content/plugins/article-forum-connect/vendor/xfapi/xfapi-php/src/Client.php(211): XFApi\Client->request('POST', 'threads', Array, Array, Array)
#2 /var/www/host_user/data/www/localhost/wp-content/plugins/article-forum-connect/vendor/xfapi/xfapi-php/src/Domain/AbstractDomain.php(67): XFApi\Client->post('threads', Array, Array, Array)
#3 /var/www/host_user/data/www/localhost/wp-content/plugins/article-forum-connect/vendor/xfapi/xfapi-php/src/Domain/XF/ThreadDomain.php(16): XFApi\Domain\AbstractDomain->post('threads', Array, Array)
#4 /var/www/host_user/data/www/localhost/wp-content/plugins/article-forum-connect/src/AudentioForumConnect/Actions/TransitionPostStatus.php(102): XFApi\Domain\XF\ThreadDomain->create('2', 'Demo', 'test demo\n\n[URL...', Array)
#5 /var/www/host_user/data/www/localhost/wp-includes/class-wp-hook.php(307): AudentioForumConnect\Actions\TransitionPostStatus::callback('publish', 'auto-draft', Object(WP_Post))
#6 /var/www/host_user/data/www/localhost/wp-includes/class-wp-hook.php(331): WP_Hook->apply_filters(NULL, Array)
#7 /var/www/host_user/data/www/localhost/wp-includes/plugin.php(476): WP_Hook->do_action(Array)
#8 /var/www/host_user/data/www/localhost/wp-includes/post.php(5303): do_action('transition_post...', 'publish', 'auto-draft', Object(WP_Post))
#9 /var/www/host_user/data/www/localhost/wp-includes/post.php(4563): wp_transition_post_status('publish', 'auto-draft', Object(WP_Post))
#10 /var/www/host_user/data/www/localhost/wp-includes/post.php(4775): wp_insert_post(Array, true, false)
#11 /var/www/host_user/data/www/localhost/wp-includes/rest-api/endpoints/class-wp-rest-posts-controller.php(831): wp_update_post(Array, true, false)
#12 /var/www/host_user/data/www/localhost/wp-includes/rest-api/class-wp-rest-server.php(1143): WP_REST_Posts_Controller->update_item(Object(WP_REST_Request))
#13 /var/www/host_user/data/www/localhost/wp-includes/rest-api/class-wp-rest-server.php(990): WP_REST_Server->respond_to_request(Object(WP_REST_Request), '/wp/v2/posts/(?...', Array, NULL)
#14 /var/www/host_user/data/www/localhost/wp-includes/rest-api/class-wp-rest-server.php(414): WP_REST_Server->dispatch(Object(WP_REST_Request))
#15 /var/www/host_user/data/www/localhost/wp-includes/rest-api.php(394): WP_REST_Server->serve_request('/wp/v2/posts/11...')
#16 /var/www/host_user/data/www/localhost/wp-includes/class-wp-hook.php(307): rest_api_loaded(Object(WP))
#17 /var/www/host_user/data/www/localhost/wp-includes/class-wp-hook.php(331): WP_Hook->apply_filters('', Array)
#18 /var/www/host_user/data/www/localhost/wp-includes/plugin.php(524): WP_Hook->do_action(Array)
#19 /var/www/host_user/data/www/localhost/wp-includes/class-wp.php(398): do_action_ref_array('parse_request', Array)
#20 /var/www/host_user/data/www/localhost/wp-includes/class-wp.php(770): WP->parse_request('')
#21 /var/www/host_user/data/www/localhost/wp-includes/functions.php(1330): WP->main('')
#22 /var/www/host_user/data/www/localhost/wp-blog-header.php(16): wp()
#23 /var/www/host_user/data/www/localhost/index.php(17): require('/var/www/host_user...')
#24 {main}
thrown in /var/www/host_user/data/www/localhost/wp-content/plugins/article-forum-connect/vendor/xfapi/xfapi-php/src/Client.php on line 396
[04-Jun-2022 15:05:21 UTC] PHP Fatal error: Uncaught XFApi\Exception\RequestException\NoPermissionRequestException: You do not have permissions to view this page or perform this action. in /var/www/host_user/data/www/localhost/wp-content/plugins/article-forum-connect/vendor/xfapi/xfapi-php/src/Client.php:396
Stack trace:
#0 /var/www/host_user/data/www/localhost/wp-content/plugins/article-forum-connect/vendor/xfapi/xfapi-php/src/Client.php(362): XFApi\Client->handleException(403, Array)
#1 /var/www/host_user/data/www/localhost/wp-content/plugins/article-forum-connect/vendor/xfapi/xfapi-php/src/Client.php(211): XFApi\Client->request('POST', 'threads', Array, Array, Array)
#2 /var/www/host_user/data/www/localhost/wp-content/plugins/article-forum-connect/vendor/xfapi/xfapi-php/src/Domain/AbstractDomain.php(67): XFApi\Client->post('threads', Array, Array, Array)
#3 /var/www/host_user/data/www/localhost/wp-content/plugins/article-forum-connect/vendor/xfapi/xfapi-php/src/Domain/XF/ThreadDomain.php(16): XFApi\Domain\AbstractDomain->post('threads', Array, Array)
#4 /var/www/host_user/data/www/localhost/wp-content/plugins/article-forum-connect/src/AudentioForumConnect/Actions/TransitionPostStatus.php(102): XFApi\Domain\XF\ThreadDomain->create('2', 'Demo', 'test demo\n\n[URL...', Array)
#5 /var/www/host_user/data/www/localhost/wp-includes/class-wp-hook.php(307): AudentioForumConnect\Actions\TransitionPostStatus::callback('publish', 'publish', Object(WP_Post))
#6 /var/www/host_user/data/www/localhost/wp-includes/class-wp-hook.php(331): WP_Hook->apply_filters(NULL, Array)
#7 /var/www/host_user/data/www/localhost/wp-includes/plugin.php(476): WP_Hook->do_action(Array)
#8 /var/www/host_user/data/www/localhost/wp-includes/post.php(5303): do_action('transition_post...', 'publish', 'publish', Object(WP_Post))
#9 /var/www/host_user/data/www/localhost/wp-includes/post.php(4563): wp_transition_post_status('publish', 'publish', Object(WP_Post))
#10 /var/www/host_user/data/www/localhost/wp-includes/post.php(4775): wp_insert_post(Array, false, true)
#11 /var/www/host_user/data/www/localhost/wp-admin/includes/post.php(426): wp_update_post(Array)
#12 /var/www/host_user/data/www/localhost/wp-admin/post.php(227): edit_post()
#13 {main}
thrown in /var/www/host_user/data/www/localhost/wp-content/plugins/article-forum-connect/vendor/xfapi/xfapi-php/src/Client.php on line 396
XFApi\Client->handleException(403, Array)
, so it's not accepting the API details. The only reason for this will be if the provided values are incorrect.We use essential cookies to make this site work, and optional cookies to enhance your experience.