Skip to content
Advertisement

Datetime to Timestamp in milliseconds in PHP

I would like to create a timestamp in milliseconds from the input ‘2016-03-22 14:30’. Also the timezone specified should be Australia/Sydney.

I’ve tried different approaches but none seem to be working.

Can anyone help me please? I’m really struggling with that.

Advertisement

Answer

Pretty self explanatory code, so I wont say much.

JavaScript

If you want to display it properly.

JavaScript
User contributions licensed under: CC BY-SA
1 People found this is helpful
Advertisement