WP-API Custom Post Type json_no_route

I think what is missing in your code is the “add_action” call for your plugin init function, so all gets instantiated correctly within wp_json_server_before_serve hook. Should be something like this (note the last line): function quizno_api_init($server) { global $quizno_api_quiz; $quizno_api_quiz = new QN_API_Quiz($server); $quizno_api_quiz->register_filters(); } add_action( ‘wp_json_server_before_serve’, ‘quizno_api_init’ );

Issue removing Media Editor Tabs — Duplicate Items

Changing strings to null or to empty strings removes items from left menu of the uploader and corresponding tabs. Paste this code in functions.php: function remove_media_tab( $strings ) { if( !current_user_can( ‘administrator’ ) ) { $strings[“createGalleryTitle”] = “”; $strings[“setFeaturedImageTitle”] = “”; $strings[“insertFromUrlTitle”] = “”; $strings[‘createPlaylistTitle’] = “”; $strings[‘createVideoPlaylistTitle’] = “”; } return $strings; } add_filter( … Read more

Apparent errer when installing plugin

I found the problem. I didn’t realize this was a generic message for pretty much all errors. I stripped everything out of the activation routine (similar to above) and ran it… got no errors. Started adding “stuff” back. And it appears a call to flush() at the end of the activation function trying to force … Read more

Call a function for social sharing

I actually link to the wrong post although this post should still help you. The actual post I wanted to link to was this one You should use this second link as a guide as there are some issues with your code, although not major. The biggest concern here is your repetition of code To … Read more

Designing a plugin that uses an iFrame to process data in admin

You could target admin-post.php to do the processing via the admin_post_$youraction hook: This hook allows you to create custom handlers for your own custom GET and POST requests. The admin_post_ hook follows the format “admin_post_$youraction”, where $youraction is your GET or POST request’s ‘action’ parameter. You can output the URL via admin_url( ‘admin-post.php?action=add_foobar’ ). Then … Read more