Convert Textual date to Timestamp with jQuery

Viewed 26

I have this textual date: "4 September 2022" (literally a text label inserted manually)

How can I convert it in timestamp with jQuery?

1 Answers

You can do it using new Date() & getTime()

Check this example.

const timestamp = new Date("4 September 2022").getTime();

console.log(timestamp);

Related