在joomla中查询的分页

I've an article in joomla 3 with php code like this:

$query="SELECT * FROM bello ORDER BY name ASC";
$result = mysql_query($query) or die(mysql_error());
while($row = mysql_fetch_array($result)){


echo $row['name']." ".$row['surname']." ".$row['age']."<br/><br/>";
}

Now, because this table bello is full of data, I'd like to da a pagination of the result..I've tried to use jquery or php methods but in Joomla it seems don't work

How can I solve this problem?