I'm building a plugin for WP that use AJAX functionality. I define 'wp_ajax_my_action' and it works good. Should I handle 'wp_ajax_nopriv' if I do not need access for non 'authenticated' users. This AJAX should work only in the admin side.
2条回答 默认 最新
- dsbo44836129 2017-05-01 14:36关注
If the AJAX action is only necessary for logged in users then you don't need the
wp_ajax_nopriv_{action}
hook.本回答被题主选为最佳回答 , 对您是否有帮助呢?解决 无用评论 打赏 举报