Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

vinay049
vinay049
Offline

Badges

Badges
11

Accepted Solutions

Accepted Solutions
0

Likes

Likes
6

Posts

Posts
28

Discussions

Discussions
0

Questions

Questions
27

Ideas

Ideas
0

Blog Posts

Blog Posts
0
Top badges earned by vinay049
Customize the badges you want to showcase on your profile
Re: How to translate small piece of content within email template body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
David's answer helped me.

Views

122

Like

1

Replies

1
Re: How to translate small piece of content within email template body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
This worked. I noticed the difference and what was the issue. Thank you

Views

123

Like

1

Replies

0
Re: How to translate small piece of content within email template body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
Hi David, Thank you for the reply. Isn't it possible to do this without using any external libraries? I tried to use the following code, but it didn't work out: Last day of the month is: <% function daysInMonth(today) { return new Date(today.getFullYear(), today.getMonth(), 0).getDate(); } function month_fr(today){ var monthFr:["Janvier", "Février", "Mars", "Avril", "Mai", "Juin", "Juillet", "Aout", "Septembre", "Octobre","Novembre","Décembre"]; var thisMonthFr = monthFr[today.getMonth()]; retur...

Views

175

Like

1

Replies

2
Re: Dynamic Date in Subject and email body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
Hi Laurent, After using that snippet, I analyzed the delivery and it didn't have any error. But when I sent that email as proof, it didn't come out. I don''t now where I should check logs in such case. Also, similar thing happened with some other code in the past.

Views

186

Likes

0

Replies

1
Re: How to translate small piece of content within email template body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
Hi Kapil, Thank you for your reply. I have seen this video and this helped me understand how to use blocks. I'm having 2 different deliveries as per language preference so there isn't use of conditional statement. But I'm trying to figure out how to use JS specific code so that I could have month's name in French in email body as well as subject. JS Code I pasted above worked in a simple HTML but it doesn't work in ACM as it doesn't support toLocale. Can you please help with that?

Views

182

Like

1

Replies

0
Re: Dynamic Date in Subject and email body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
Thanks for providing the location for editing. After using that snippet, email didn't come through from ACM to inbox. Can you please let me know what might be the issue ?

Views

199

Likes

0

Replies

3
Re: Dynamic Date in Subject and email body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
Thank you for revert.I used below mentioned approach but it didn't work out. Can you plz tell me why? Last day of the month is: <% function daysInMonth(today) { return new Date(today.getFullYear(), today.getMonth(), 0).getDate(); } function month_fr(today){ var options = { weekday: 'long', year: 'numeric', month: 'long', day: 'numeric' }; return today.toLocaleDateString("fr-FR", { month: 'long'}); } var today = new Date(); %> <%= daysInMonth(today) %> <%= month_fr(today) %>, <%= formatDate (toda...

Views

203

Likes

0

Replies

5
How to translate small piece of content within email template body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
Hi everyone, I'm rendering dynamic content using JavaScript and it is in English for one email delivery. I want to use same JavaScript for content that should be in another language. For example, I'm displaying month name dynamically in email subject as well as email body in English. I want to display the same in French. I'm newbie with ACM. Can anyone help me how I can do that? I'm using following snippet for email subject for EN -<%= formatDate(new Date(), "%Bl") %> And following snippet for e...

Views

197

Like

1

Replies

9
Re: Dynamic Date in Subject and email body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
Another implementation way - just corrected snippet for month. Found that in JS, month is 0-based so it was creating the issue.<%function daysInMonth(today) { return new Date(today.getFullYear(), today.getMonth()+1, 0).getDate();}var today = new Date();%><%= daysInMonth(today) %> <%= formatDate (today, "%Bl") %> Can you help with translation part?

Views

265

Likes

0

Replies

0
Re: Dynamic Date in Subject and email body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
Hi Laurent, Also, the number of days for October is coming as "30" in place of "31" with this code. Do you know the reason ?

Views

213

Likes

0

Replies

0
Re: Dynamic Date in Subject and email body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
Hi Laurent, I need one more help. Your answer did work. If I want to have month name in French in subject as well as email body. Do you know how to do that?

Views

267

Likes

0

Replies

8
Re: Dynamic Date in Subject and email body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
Hi Anthony, I need one more help. Selected answer did work. If I want to have month name in French in subject as well as email body. Do you know how to do that?

Views

212

Likes

0

Replies

0
Re: Dynamic Date in Subject and email body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
Thank you so much Anthony for your help, time and efforts.

Views

224

Like

1

Replies

0
Re: Dynamic Date in Subject and email body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
Thank you so much, this snippet worked for me.

Views

299

Likes

0

Replies

0
Re: Dynamic Date in Subject and email body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
Update: Hello <%=recipient.firstName%> and month - <%= formatDate(new Date(), "%Bl") %> This one also worked in the email body. So I think there's issue with snippet for getting max number of days in a month. Can you please help ?

Views

225

Likes

0

Replies

2
Re: Dynamic Date in Subject and email body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
I kept subject as Test Email and used Hello <%=recipient.firstName%>inside email body. It worked. Also, I used <%= formatDate(new Date(), "%Bl") %> in the subject and Hello <%=recipient.firstName%> in the email body. It worked. But I'm not sure why formatDate isn't working email body. Also, I'm sending this email as proof email so I'm not able to find anything in the delivery.

Views

226

Likes

0

Replies

3
Re: Dynamic Date in Subject and email body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
I just tried to use <%=formatDate(getCurrentDate(),"%2D %Bl %4Y")%>in the email body and that email didn't come through either. Can anyone please tell me what might be the issue ? This snippet does work in the email subject.

Views

254

Likes

0

Replies

5
Re: Dynamic Date in Subject and email body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
I'm using AC Classic 7.0.19.1 build I'm not sure why but I can send test emails. but not with any condition. I did check deliveries but couldn't find anything. I'm trying to send such email via "send a proof". so I think deliveries aren't there. While I try to send this email as a proof, there isn't any error while I analyze it.

Views

256

Likes

0

Replies

6
Re: Dynamic Date in Subject and email body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
Thank you for suggestion Lauren. I will try this way today and let you know whether that worked or not.

Views

351

Likes

0

Replies

0
Re: Dynamic Date in Subject and email body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
I'm not sure what's the issue. I have removed the entire email. And created simple HTML using the code given above. I didn't receive the test email. Is there any configuration related issue in MS Outlook for receiving email written with JS or configuration issue in ACM or anyother issue? Because without that snippet, I can send and receive all the emails. Subject snippet did work but issue is with only this snippet. Also, note that I can use dynamic first name in the body by Hi <%= recipient.fir...

Views

387

Likes

0

Replies

22
Re: Dynamic Date in Subject and email body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
Yes, I have followed the steps mentioned by you. Used ";" in between, but it didn't work. Removed that snippet and sent test email, Got email. But when I put that snippet in, not able to receive the email. I have used something like this This is test email and needs to be done by <% var d = new Date(); var m = d.getMonth(); var y = d.getFullYear(); var lastDate = new Date(y, m + 1, 0); var dateString = formatDate(lastDate,"%2D %Bl %4Y"); document.write(dateString) %>

Views

392

Likes

0

Replies

24
Re: Dynamic Date in Subject and email body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
Hi Anthony, I have tried to use the code but I don't receive test emails at all after using it. I have used the code in the email body HTML as suggested above. Do I need to put this somewhere else? also, do I need to add any syntax? For example,I have used this snippet like - This is test snippet and you need to complete this test by <% var d = new Date() var m = d.getMonth() var y = d.getFullYear() var lastDate = new Date(y, m + 1, 0); var dateString = formatDate(lastDate,"%2D %Bl %4Y") docume...

Views

398

Likes

0

Replies

26
Re: Dynamic Date in Subject and email body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
Thank you for your reply, Anthony. For subject line - this will work. For body - let me clarify what I'm trying to do. I want to display max number of days in the current month, current month name and current year. For example, 30 September, 31 October, 30 November and so on. February - it will be trickier month. I'm trying to figure out how to do this. Do you have any idea for this?

Views

408

Likes

0

Replies

28
Re: Dynamic Date in Subject and email body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
Thank you for your reply, Deb. For subject line - this will work. For body - let me clarify what I'm trying to do. I want to display max number of days in the current month, current month name and current year. For example, 30 September, 31 October, 30 November and so on. February - it will be trickier month. I'm trying to figure out how to do this.

Views

409

Likes

0

Replies

0
Re: Dynamic Date in Subject and email body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
Hi Anthony, Tank you so much for your reply and suggestion. I think I need to clarify the question. I want to do 2 things: 1. I want to display current month name in the email subject For example, welcome email - September 2. I want to display number of days in the current month, month name and year in the email body. For example, 30 September 2021. This should be dynamic. I'm trying to figure out how to do this in ACM - Email Delivery - HTML file for email body and email subject within the Emai...

Views

427

Likes

0

Replies

30
Re: Dynamic Date in Subject and email body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
Thank you for your reply. How to use format date for dynamic month in subject? Also, how to fetch number of days in a particular month and current month as dynamic one in the email body?

Views

445

Likes

0

Replies

2
Dynamic Date in Subject and email body
Avatar
Boost 5
Level 2
vinay049
Level 2

Likes

6 likes

Total Posts

28 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back 25
Boost 3
Boost 1
Validate 1
View profile
vinay049
- Adobe Campaign Classic
Hi everyone,I'm new to Adobe Campaign Manager and I'm trying to use dynamic date in the email subject and email body. By dynamic date I meant is - days in month followed by month name - i.e. 30 September, 31 October and so on. Also, needs to consider February as a special case. Can anyone please tell me how I can do this in the email template? I can create HTML file and use javascript within the HTML but I'm not sure whether it is permissible to use such HTML as email delivery HTML in ACM. Also,...

Views

677

Likes

0

Replies

36