ex:
while ($row_result = mysql_fetch_assoc($result))
{
<td width="20%"><div align="center"><a href="detalhe.php?id=<?php echo $row_result['id']; ?>" onmouseover="doTooltip(event,0)" onmouseout="hideTip()"><img src="imagens/viaturas/<?php echo $row_result['foto_1']; ?>" width="66" height="45" border="0" style="border: solid 1px #FFFFFF"/></a></div></td>
}
Regards,
Scroll