| @@ 552-564 (lines=13) @@ | ||
| 549 | ||
| 550 | if ( preg_match("#^$match#", $request_match, $matches) ) { |
|
| 551 | ||
| 552 | if ( $wp_rewrite->use_verbose_page_rules && preg_match( '/pagename=\$matches\[([0-9]+)\]/', $query, $varmatch ) ) { |
|
| 553 | // This is a verbose page match, let's check to be sure about it. |
|
| 554 | $page = get_page_by_path( $matches[ $varmatch[1] ] ); |
|
| 555 | if ( ! $page ) { |
|
| 556 | continue; |
|
| 557 | } |
|
| 558 | ||
| 559 | $post_status_obj = get_post_status_object( $page->post_status ); |
|
| 560 | if ( ! $post_status_obj->public && ! $post_status_obj->protected |
|
| 561 | && ! $post_status_obj->private && $post_status_obj->exclude_from_search ) { |
|
| 562 | continue; |
|
| 563 | } |
|
| 564 | } |
|
| 565 | ||
| 566 | // Got a match. |
|
| 567 | // Trim the query of everything up to the '?'. |
|
| @@ 234-246 (lines=13) @@ | ||
| 231 | if ( preg_match("#^$match#", $request_match, $matches) || |
|
| 232 | preg_match("#^$match#", urldecode($request_match), $matches) ) { |
|
| 233 | ||
| 234 | if ( $wp_rewrite->use_verbose_page_rules && preg_match( '/pagename=\$matches\[([0-9]+)\]/', $query, $varmatch ) ) { |
|
| 235 | // This is a verbose page match, let's check to be sure about it. |
|
| 236 | $page = get_page_by_path( $matches[ $varmatch[1] ] ); |
|
| 237 | if ( ! $page ) { |
|
| 238 | continue; |
|
| 239 | } |
|
| 240 | ||
| 241 | $post_status_obj = get_post_status_object( $page->post_status ); |
|
| 242 | if ( ! $post_status_obj->public && ! $post_status_obj->protected |
|
| 243 | && ! $post_status_obj->private && $post_status_obj->exclude_from_search ) { |
|
| 244 | continue; |
|
| 245 | } |
|
| 246 | } |
|
| 247 | ||
| 248 | // Got a match. |
|
| 249 | $this->matched_rule = $match; |
|