I have been trying to get PHP to retrieve any results that have the date stamp that is the same as in the column 'date'.
It then loops round and prints out all the data retrieved.
The actual retrieval works fine, its just my condition!
Code:
$currentdate = date('Y/m/d');
$echo . $currentdate;
$query = "SELECT * FROM `pupils` WHERE `$currentdate` = date";//Grab the data
$result = mysqli_query($con, $query);
Any help greatly appreciated!
$echoerrrr, that's justecho;-)echo $currentdate;and no dot required.