Hvordan ser din kode ud Jesper?
Sådan her;
- echo "<td>" .
- $days = array("Mandag","Tirsdag", "Onsdag","Torsdag","Fredag","Lørdag","Søndag");
- $months = array("Jan", "Feb", "Mar", "Apr", "Maj", "Jun", "Jul", "Aug", "Sep", "Okt", "Nov", "Dec");
- $timestamp = strtotime($c->pubDate);
- $dayInWeek = $days[date('N', $timestamp)-1];
- $month = $months[date('n', $timestamp)-1];
- $dayInMonth = date('d', $timestamp);
- $year = date('Y', $timestamp);
- echo $dayInWeek . ' ' .$dayInMonth. ' '.$month.' '.$year
- . "</td>";
EIDT VIRKER NU!
- $days = array("Mandag", "Tirsdag", "Onsdag", "Torsdag", "Fredag", "Lørdag", "Søndag");
- $months = array("Jan", "Feb", "Mar", "Apr", "Maj", "Jun", "Jul", "Aug", "Sep", "Okt", "Nov", "Dec");
- $timestamp = strtotime($c->pubDate);
- $dayInWeek = $days[date('N', $timestamp)-1];
- $month = $months[date('n', $timestamp)-1];
- $dayInMonth = date('d', $timestamp);
- $year = date('Y', $timestamp);
-
- echo "<td>$dayInWeek $dayInMonth $month $year</td>";
Indlæg senest redigeret d. 16.06.2013 18:41 af Bruger #17136