Formula to add in HTML for date "today plus 30d" | Community
Skip to main content
florianf6984149
June 15, 2021
Solved

Formula to add in HTML for date "today plus 30d"

  • June 15, 2021
  • 2 replies
  • 1867 views

Hi, I want to add a date in my HTML: not today but "today plus 30d". Anyone able to tell me the formula to add into the HTML? Many thanks!!!

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by jamal

Hi Florian,

 

I suggest transforming the date value as additional data/enrichment before putting it in the email html by referencing additional data. You can do this by using the expression: AddDays(GetDate(),30), if you want it to be exactly one month later, then you can just use AddMonths(GetDate(),1).

 

Cheers,

Jamal

2 replies

jamalAccepted solution
Level 2
June 21, 2021

Hi Florian,

 

I suggest transforming the date value as additional data/enrichment before putting it in the email html by referencing additional data. You can do this by using the expression: AddDays(GetDate(),30), if you want it to be exactly one month later, then you can just use AddMonths(GetDate(),1).

 

Cheers,

Jamal

Adobe Employee
June 25, 2021

You can do it either using an enrichment as recommended above or else using a JavaScript content block.

Within the content block you also can format the date in the desired format easily