cturner Posted October 24, 2006 Share Posted October 24, 2006 When I test the following code the rows ($row['date'] and $row['diary_entry']) don't display. Can someone please tell me why and how I can fix it? Thanks in advance.[code]require "config.php";// get the entry date$entry_date = $_GET['entry_date'];$date = date("j F Y", $entry_date);// select the diary entry for the entry_date$query = mysql_query("SELECT * FROM `diary_contents` WHERE `date` = '$date' LIMIT 1") or die ("Could not query because: ".mysql_error());// display the diary entries for the entry date// display the selected dateecho "Posted on: ".$date;// display the selected diary entrywhile($row = mysql_fetch_array($query)){ // Build your formatted results here. echo $row['date']; echo $row['diary_entry'];}[/code] Link to comment https://forums.phpfreaks.com/topic/24985-rows-arent-displaying-from-the-query/ Share on other sites More sharing options...
cturner Posted October 24, 2006 Author Share Posted October 24, 2006 Sorry I have solved the problem. Link to comment https://forums.phpfreaks.com/topic/24985-rows-arent-displaying-from-the-query/#findComment-113861 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.