Print to video database

Good evening everyone, I created this file to be able to print the data from the database on the screen.
Everything ok but all the data contained in the database appear on the same line.
I would like them to print like this:

nome email titolo dataeora msg
nome email titolo dataeora msg
nome email titolo dataeora msg
etc. etc.

This is the code:

?php

// dati di connessione al mio database MySQL
$db_host = 'localhost';
$db_user = 'xx';
$db_pass = 'xx';
$db_name = 'xx';

// connessione al DB utilizzando MySQLi
$cn = new mysqli($db_host, $db_user, $db_pass, $db_name);

// verifica su eventuali errori di connessione
if ($cn->connect_errno) {
    echo "Connessione fallita: ". $cn->connect_error . ".";
    exit();
}

$query = "SELECT * FROM test";
$oggetto =$cn->query($query);

echo "<table><tr>";
echo "<th>nome</th><th>email</th><th>titolo</th><th>dataeora</th><th>msg</th>";
echo "</tr>";


while($scorri_oggetto=$oggetto->fetch_assoc()){
?>
<th><?php printf($scorri_oggetto['nome']);?></th>
<th><?php printf($scorri_oggetto['email']);?></th>
<th><?php printf($scorri_oggetto['titolo']);?></th>
<th><?php printf($scorri_oggetto['dataeora']);?></th>
<th><?php printf($scorri_oggetto['msg']);?></th>
<?php
}


echo "</table>";

// chiusura della connessione
$cn->close();
?>  

what am I wrong? Can you fix me? Thanks