AnsPress_Theme::post_actions()
Description #
Ajax callback for post actions dropdown.
Source #
File: includes/class-theme.php
public static function post_actions() { $post_id = (int) ap_sanitize_unslash( 'post_id', 'r' ); if ( ! check_ajax_referer( 'post-actions-' . $post_id, 'nonce', false ) || ! is_user_logged_in() ) { ap_ajax_json( 'something_wrong' ); } ap_ajax_json( array( 'success' => true, 'actions' => ap_post_actions( $post_id ), ) ); }
Expand full source code Collapse full source code View on GitHub: includes/class-theme.php:227
Add your comment