Bien,
el código quedaría así:
Código PHP:
<html>
<head>
</head>
<body>
<?php
//llamada a la base de datos
$hostname = "el que sea";
$database = "el que sea";
$username = "el que sea";
$password = "el que sea";
$conexion = mysql_pconnect($hostname, $username, $password) or trigger_error(mysql_error(),E_USER_ERROR);
mysql_select_db($database,$conexion);
$sql="SELECT *
FROM tubd";
$res=mysql_query($sql,$conexion) or die(mysql_error()."<br />".$sql."<hr />");
echo '<table>
<tr>
<td>Tipo venta</td>
<td>Directo</td>
<td>Indirecto</td>
<td>Anulado</td>
<td>Totales</td>
</tr>';
while($registro=mysql_fetch_assoc($res)) {
echo '<tr>
<td>'.$registro['tipoventa'].'</td>
<td>'.$registro['directo'].'</td>
<td>'.$registro['indirecto'].'</td>
<td>'.$registro['anulado'].'</td>
<td>'.$registro['totales'].'</td>
</tr>';
}
echo '</table>';
?>