Use strpos instead of strstr where ever possible, for speed. Props rob1n. fixes #3920

git-svn-id: https://develop.svn.wordpress.org/trunk@4990 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Mark Jaquith
2007-03-07 05:29:15 +00:00
parent 5b1ff4fbd5
commit 56368548ad
26 changed files with 82 additions and 84 deletions
+1 -1
View File
@@ -280,7 +280,7 @@ function check_admin_referer($action = -1) {
$adminurl = strtolower(get_option('siteurl')).'/wp-admin';
$referer = strtolower(wp_get_referer());
if ( !wp_verify_nonce($_REQUEST['_wpnonce'], $action) &&
!(-1 == $action && strstr($referer, $adminurl)) ) {
!(-1 == $action && strpos($referer, $adminurl) !== false))
wp_nonce_ays($action);
die();
}