Your first example also needs the orderby
parameter set, otherwise it defaults to standard date order:
$my_query = new WP_Query(
array(
'post_type' => 'slider',
'post__in' => $posts,
'orderby' => 'post__in'
)
);
Your first example also needs the orderby
parameter set, otherwise it defaults to standard date order:
$my_query = new WP_Query(
array(
'post_type' => 'slider',
'post__in' => $posts,
'orderby' => 'post__in'
)
);