Jump to content

date_format()


RON_ron

Recommended Posts

Can someone tell me what is the fault with my code?

 

SELECT date_format(datecolumn,'%d %M %Y') as date FROM news WHERE article_id=$id

 

$query = "SELECT * FROM  my_db ORDER BY timestamp DESC";

$results = mysql_query($query);

 

$returnS="";

while($line = mysql_fetch_array($results))

{

$returnS.= $line["subject"].",,".$line["$id"].",,".$line["article"].",,".$line["link"].",,,";

}

echo $returnS;

mysql_close($link);

?>

Link to comment
https://forums.phpfreaks.com/topic/210563-date_format/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.