I need to be able to change the date format from Y/M/D to D/M/Y. The database with all the data that I am querying has the date set as Y/M/D whereas the input form has the input yet as D/M/Y.
Does anyone have any idea how I can change the format?
NB the Date is 'DOB'
Here is the SQL:
$sql="SELECT `country_name`,`gdp`,`population`,Cyclist.name,Cyclist.dob FROM Country JOIN Cyclist ON Country.ISO_id=Cyclist.ISO_id
WHERE 'dob'
BETWEEN '".$date_1."' AND '".$date_2."'";
Here is the PHP for getting the data from the form submission
$date_1=$_REQUEST['date_1'];
$date_2=$_REQUEST['date_2'];