<?php if ($row_ventas['fecha'] != "0000-00-00"){echo date('d-m-Y',strtotime($row_ventas['fecha']));} ?>