[wp-hackers] meta_value contains text

Ashok Padda ashok.padda at gmail.com
Sun Aug 16 21:30:23 UTC 2009


You may have to use OR, instead of AND. Try following, instead.

    $where .= " AND ( meta_key = '$key' AND meta_value LIKE('%$val%') ) OR
meta_value = 'foo' ";


More information about the wp-hackers mailing list