Answers for "input type date current date php"

PHP
1

how assign current date to input type date html in php

<input type="date" value="<?php echo date("Y-m-d"); ?>">
Posted by: Guest on December-01-2021
0

current date time in php for input

<input type="datetime-local" name="followupon" value=<?php echo date('Y-m-dTH:i:s'); ?>">
Posted by: Guest on May-03-2021
0

get current date from year input php

$date_input = '2003';
$date_output= date( "Y-m-d", mktime( 0, 0, 0, 1, 1, $date_input ));
//date_output = 2003-01-01
Posted by: Guest on July-17-2020

Browse Popular Code Answers by Language