Make WordPress Core


Ignore:
Timestamp:
10/18/2009 11:50:59 AM (14 years ago)
Author:
westi
Message:

Remove duplicated create_function calls an use a private _search_terms_tidy function instead for tidying up the post/page searching when looking to attach orphans to a parent post or page.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/admin-ajax.php

    r12036 r12052  
    11981198    $s = stripslashes($_POST['ps']);
    11991199    preg_match_all('/".*?("|$)|((?<=[\\s",+])|^)[^\\s",+]+/', $s, $matches);
    1200     $search_terms = array_map(create_function('$a', 'return trim($a, "\\"\'\\n\\r ");'), $matches[0]);
     1200    $search_terms = array_map('_search_terms_tidy', $matches[0]);
    12011201
    12021202    $searchand = $search = '';
Note: See TracChangeset for help on using the changeset viewer.