Created
December 3, 2014 04:27
-
-
Save modemlooper/c004802c8c19ef6ea952 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function custom_json_api_prepare_post( $post_response, $post, $context ) { | |
$post_response['do_api_action']['default']['above_title'] = 'this is above the title'; | |
$post_response['do_api_action']['default']['below_title'] = 'this is below the title'; | |
$post_response['do_api_action']['default']['above_content'] = 'this is above the content'; | |
$post_response['do_api_action']['default']['below_content'] = 'this is below the content'; | |
return $post_response; | |
} | |
add_filter( 'json_prepare_post', 'custom_json_api_prepare_post', 10, 3 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment