I get a date from the database in this format
hh:mm:ss
And I want to add this to the current time and put back to an other table with the following format:
yyyy:mm:dd hh:mm:ss
I get a date from the database in this format
hh:mm:ss
And I want to add this to the current time and put back to an other table with the following format:
yyyy:mm:dd hh:mm:ss
Edit: Try this instead:
Assuming you get the time from the database in a variable $dbTime I'd do something like this:
May not be the cleanest way but it is an option :)
From your question, I understand that you want your time value from database to be added in the current date time value. Here is the code to do so:-
Hope this helps. Thanks.