Make WordPress Core

Opened 14 years ago

Closed 12 years ago

#13278 closed enhancement (duplicate)

query.php, exclude posts by more authors bug

Reported by: aesqe's profile aesqe Owned by: ryan's profile ryan
Milestone: Priority: normal
Severity: normal Version:
Component: Query Keywords:
Focuses: Cc:


in latest nightly on lines 2053 - 2054:

$q['author'] = explode('-', $q['author']);
$q['author'] = (string)absint($q['author'][1]);

just removing 'absint' from line 2054 would enable queries like this following one to give expected results (posts where author ids are not 1 or 2):


replacing both lines with something like this:

$q['author'] = str_replace('-', '', $q['author']);

would also allow this input:


currently, these queries just exclude the author whose ID is first in list.

Change History (3)

#1 @nacin
14 years ago

  • Milestone changed from 3.0 to 3.1

#2 @nacin
14 years ago

  • Milestone changed from Awaiting Triage to Future Release
  • Type changed from defect (bug) to enhancement

#3 @SergeyBiryukov
12 years ago

  • Milestone Future Release deleted
  • Resolution set to duplicate
  • Status changed from new to closed

#16854 has a patch.

Note: See TracTickets for help on using tickets.