From 9b0101e59df0aabf935239242fb06ce4e9dd2640 Mon Sep 17 00:00:00 2001 From: Andrew Nacin Date: Sat, 29 Mar 2014 05:17:57 +0000 Subject: [PATCH] Rewrite: Use same delimiter in url_to_postid() we use in WP::parse_request(). props stevenkword. fixes #23587. git-svn-id: https://develop.svn.wordpress.org/trunk@27835 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/rewrite.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/wp-includes/rewrite.php b/src/wp-includes/rewrite.php index 6a3dd58ce8..1b834c829e 100644 --- a/src/wp-includes/rewrite.php +++ b/src/wp-includes/rewrite.php @@ -362,7 +362,7 @@ function url_to_postid($url) { if ( !empty($url) && ($url != $request) && (strpos($match, $url) === 0) ) $request_match = $url . '/' . $request; - if ( preg_match("!^$match!", $request_match, $matches) ) { + if ( preg_match("#^$match#", $request_match, $matches) ) { if ( $wp_rewrite->use_verbose_page_rules && preg_match( '/pagename=\$matches\[([0-9]+)\]/', $query, $varmatch ) ) { // this is a verbose page match, lets check to be sure about it