How can I get the current date of the server and put it in my query to send to the bank? I do not have the slightest idea how I can get the current time and put in a variable to send to the bank, thank you.
How can I get the current date of the server and put it in my query to send to the bank? I do not have the slightest idea how I can get the current time and put in a variable to send to the bank, thank you.
You can do this in bank language.
If it is MySQL you can use NOW()
which gives YYYY-MM-DD HH:MM:DD
ie date and time.
In PHP there are several ways, one of them date("Y-m-d H:i:s")
, another is
$now = new DateTime();
$datetime = $now->format('Y-m-d H:i:s');