Hey guys, so I follow a tutorial here:
http://www.kirupa.com/web/sqlrecords_php2.htm
and was wondering how I would go about changing the date to DD/MM/YYYY?
Here’s a snippet to show you what I have at the moment.
$custorders = mysql_query("SELECT * FROM orders WHERE customerNumber = '$custid[customerNumber]' ");
//Set pointer to 0, so the fetch_assoc starts at first record.
$i = 0;
//Creates assoc array as long as customerNumber is matched.
while($custorders_ar = mysql_fetch_assoc($custorders))
{
?>
<table border="1" cellpadding="5">
<tr>
<th>orderNumber</th>
<th>orderDate</th>
<th>requiredDate</th>
<th>shippedDate</th>
<th>status</th>
</tr>
<tr>
<td><?php echo $custorders_ar['orderNumber']; ?></td>
<td><?php echo $custorders_ar['orderDate']; ?></td>
<td><?php echo $custorders_ar['requiredDate']; ?></td>
<td><?php echo $custorders_ar['shippedDate']; ?></td>
<td><?php echo $custorders_ar['status']; ?></td>
</tr>
</table>
<?php
$i+=1;
}
?>