get_posts() using an array of post ids [closed]

Please try this instead:

$args = array(
    'post__in' => $post_ids,
);
$posts = get_posts( $args );

Lesson learned: Always check your PHP scripting errors! 😉

Check for example this Codex page on debugging.

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)