<?php
require('include/functions.php');
$cid = 25275;
$msgs = sb_db_get('SELECT * FROM sb_messages WHERE conversation_id = ' . $cid . ' ORDER BY id DESC LIMIT 10', false);
if ($msgs) {
    foreach ($msgs as $m) {
        echo "Msg ID: " . $m['id'] . " | User: " . $m['user_id'] . " | Time: " . $m['creation_time'] . " | Msg: " . mb_substr($m['message'], 0, 50) . "...\n";
    }
} else {
    echo "No messages.";
}
?>
