         SELECT M.msg_id, M.uid_fk, M.message, M.created, U.fname, U.lname, M.uploads, M.profile_uid FROM messages M, users U WHERE M.uid_fk=U.uid AND M.profile_uid IN ($user_ids) $loadmore ORDER BY msg_id DESC ";          $query = mysqli_query($db_conx, $sql);         