$stmt = $pdo->prepare('SELECT COUNT(*) FROM messages WHERE state>5 && receive = ? OR receive = ? '); $count = $stmt->fetchColumn(); $x = (int)$count ;
$stmt = $pdo->prepare('SELECT COUNT(*) FROM messages WHERE state>5 && receive = ? OR receive = ? '); $count = $stmt->fetchColumn(); $x = (int)$count ;