php - Is it possible to change the string in an array from mysql output -
this question has answer here:
- convert 1 date format in php 12 answers
i know if possible change string format in array. in example down below change $doletzterwurm['date'] format 0000-00-00(year-month-day) day-month-year.
i know use old mysql query, change soonish ;)
<?php $search1 = "select * `wurm_stats` order `id` desc limit 1"; $letzterwurm = mysql_query($search1); while ($doletzterwurm= mysql_fetch_array($letzterwurm)) { echo "<br></br><div style='text-align:center;color:#ffffff;font-size: 24px;'>letzter wurm eintrag " .$doletzterwurm['date']. " von " .$doletzterwurm['eingetragenvon']. " </br>"; } ?>
it's possible, see date
function.
echo '[...]' . date('d-m-y', $doletzterwurm['date']) . '[...]';
Comments
Post a Comment