Hello everyone,
I try to get in my HTML delivery something like this with the date and make a personalization, here is my example :
You can travel between the 01/04/2022 until the 15/05/2022
So I want to get the first day of the current month until another day + 45 days for example.
Is something like this possible with personalization ? Can someone help me on this possible code ?
Thank you in advance for your help.
Kind regards.
EDIT :
I successfully got the first day of current month with this :
var date = new Date();
var firstDay = new Date(date.getFullYear(), date.getMonth(), 1);
Result
<%= formatDate(firstDay, "%2D/%2M/%4Y") %>
Question remain is, how to get the other date + 45 days based on the firstDay ?
Thank you for your help.