wphooks.info - press_this_save_redirect

press_this_save_redirect

(trunk - 4.9-alpha-41548)

The hook occurs in the following file:

wp-admin/includes/class-wp-press-this.php:
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
			/**
			 * Filters the URL to redirect to when Press This saves.
			 *
			 * @since 4.2.0
			 *
			 * @param string $url     Redirect URL. If `$status` is 'publish', this will be the post permalink.
			 *                        Otherwise, the default is false resulting in no redirect.
			 * @param int    $post_id Post ID.
			 * @param string $status  Post status.
			 */
			$redirect = apply_filters( 'press_this_save_redirect', $redirect, $post_id, $post_data['post_status'] );

			if ( $redirect ) {
				wp_send_json_success( array( 'redirect' => $redirect, 'force' => $forceRedirect ) );
			} else {
				wp_send_json_success( array( 'postSaved' => true ) );
			}
		}
	}