[wp-trac] [WordPress Trac] #33988: New param for search in WP Query
WordPress Trac
noreply at wordpress.org
Thu Oct 8 00:12:01 UTC 2015
#33988: New param for search in WP Query
------------------------------+------------------
Reporter: sebastian.pisula | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: 4.4
Component: Query | Version:
Severity: normal | Resolution:
Keywords: has-patch | Focuses:
------------------------------+------------------
Comment (by boonebgorges):
> Only one small thought: If we skip the sentence match in ordering, then
search results with negative terms will have different sorting. Consider
first querying for foo bar and then altering that to filter out baz: foo
bar -baz – now we present the results quite possibly in different order
and also not in the best possible order of relevance – intuitively at the
very least. But most likely the issue I described is so minor that it is
not worth looking into.
Hrm. Yeah, I agree it's slightly strange. But at the same time, I think it
makes sense that the NOT operator would sorta override the rest of the
query. It doesn't seem obvious to me what the expected behavior in this
case *ought* to be. So I think that what's in the patch is probably as
good as anything.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/33988#comment:8>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list