[wp-trac] [WordPress Trac] #27252: WP_Query's "fields" => "ids" should return an array of integers

WordPress Trac noreply at wordpress.org
Fri Mar 7 19:03:12 UTC 2014


#27252: WP_Query's "fields" => "ids" should return an array of integers
------------------------------------+------------------
 Reporter:  danielbachhuber         |       Owner:
     Type:  defect (bug)            |      Status:  new
 Priority:  normal                  |   Milestone:  3.9
Component:  Query                   |     Version:
 Severity:  normal                  |  Resolution:
 Keywords:  has-patch dev-feedback  |     Focuses:
------------------------------------+------------------

Comment (by nacin):

 I'm all for this but `post__in` appears to accept an array of numeric
 strings fine:

 {{{
 $post__in = implode(',', array_map( 'absint', $q['post__in'] ));
 }}}

--
Ticket URL: <https://core.trac.wordpress.org/ticket/27252#comment:2>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list