Admin: Custom Query Returning Permissions Error
I think the problem is that by just appending ?deleteUser=XX you get an ‘illegal’ url, for example: http://localhost/wordpress/wp-admin/edit.php?post_type=type&page=mypage?deleteUser=xxx Instead, use WordPress’ add_query_arg: $url = $_SERVER[‘REQUEST_URI’]; $url = add_query_arg(‘test’,’val’,$url); which gives: http://localhost/wordpress/wp-admin/edit.php?post_type=type&page=mypage&deleteUser=xxx Personally, I wouldn’t use $_SERVER[‘REQUEST_URI’]; and instead hard-code the url of the page using admin_url. Also, see @Joshua comments on using the WordPress in-built … Read more