Menu Adam R Brown

WP hooks navigation: Home/browseActions indexFilters index

Source View: do_redirect_guess_404_permalink

To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).

Understanding Source Code

The best way to understand what a hook does is to look at where it occurs in the source code.

Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.

Source View

Line Code
891       *
892       * Returning a false value from the filter will disable the URL guessing
893       * and return early without performing a redirect.
894       *
895       * @since 5.5.0
896       *
897       * @param bool $do_redirect_guess Whether to attempt to guess a redirect URL
898       *                                for a 404 request. Default true.
899       */
900      if ( false === apply_filters( 'do_redirect_guess_404_permalink', true ) ) {
901           return false;
902      }
903
904      /**
905       * Short-circuits the redirect URL guessing for 404 requests.
906       *
907       * Returning a non-null value from the filter will effectively short-circuit
908       * the URL guessing, returning the passed value instead.
909       *