WordPress Version: 4.6
/**
* Formerly used to escape strings before searching the DB. It was poorly documented and never worked as described.
*
* @since 2.5.0
* @deprecated 4.0.0 Use wpdb::esc_like()
* @see wpdb::esc_like()
*
* @param string $text The text to be escaped.
* @return string text, safe for inclusion in LIKE query.
*/
function like_escape($text)
{
_deprecated_function(__FUNCTION__, '4.0.0', 'wpdb::esc_like()');
return str_replace(array("%", "_"), array("\\%", "\\_"), $text);
}