People who code: we want your input. Take the Survey

Hot answers tagged

2

it adds additional value before and after each Like query That {d146fc7cb41ff444163abadd50ac5da7ec5439fd51386c3cfe2cea107126703b} is a placeholder escape string for the literal % (percent) sign used in prepared statements (see wpdb::prepare()) and the escape string is generated by wpdb::placeholder_escape(). So actually, that {...


1

You can achieve the OR relation using the tax_query argument like so: $query->set( 'tax_query', array( 'relation' => 'OR', array( 'taxonomy' => 'category', 'terms' => array( 2, 3 ), ), array( 'taxonomy' => 'post_tag', 'terms' => array( 10, 13 ), ), ) );


Only top voted, non community-wiki answers of a minimum length are eligible