I am getting the following error | Community
Skip to main content
Level 5
January 8, 2024
Solved

I am getting the following error

  • January 8, 2024
  • 2 replies
  • 2145 views

Error while compiling script 'content htmlContent' line 61: message.recipient_id is undefined. SCR-160012 Javascript: error while evaluating script 'content htmlContent'.

 

Please suggest. I looked for the following recipient-id it was not defined anywhere in the HTML. I am using visitor schema in target & filtering dimensions in queries and visitor as target mapping. 

 

THank you in advance

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 rvnth

@rvnth ,

Yes.. The script &eid=<%= message.recipient_id.toString() is trying to fetch recipient's primary key from broadLog schema. As you use Visitor's schema in target mapping, the broad log for visitor will be having visitor's schema linked and not on nms:recipient. So the script is unable to get message.recipient_id and leads to error.


Thank you @parthasarathy We found a workaround for this. As we are using the recurring delivery , we tried removing the analytics from the properties tab but did not worked.

 

Then we replaced recurring delivery with single email delivery, and removed the analytics from the properties tab, it started working. 

2 replies

Level 3
January 9, 2024

@rvnth 

You seem to have personalized content in your HTML and your text version is not genereated. I would suggest to delete the text version of email and re-generate

 

rvnthAuthor
Level 5
January 9, 2024

Thank you @mustufam5967803 . Please can you suggest how to delete the text version because I am not using anything in text version of the email. 

Level 3
January 9, 2024

Can you confirm your target recipient is same as target mapping in a delivery.

 

ParthaSarathy
Community Advisor
Community Advisor
January 9, 2024

Hi @rvnth ,

Basically HTML in your delivery uses message.recipient_id , since it has target mapping as Visitors it is unable to read recipient_id.

So, In Email HTML Content > Source code tab search for message.recipient_id

If you're unable to find it in source tab, may be you're using some personalization block in your HTML and the personalization block might have message.recipient_id. You cross check it in that particular personalization block and make modifications in it.

~  ParthaSarathy S~  Click here to join ADOBE CAMPAIGN USER GROUP for Quarterly In-person | Hybrid | Virtual Meetups
AkshayAnand
Community Advisor
Community Advisor
January 10, 2024

Hi @rvnth 

 

You can follow the detailed guide which ParthaSarathy has given, along with that you can also check in the Deliveries Properties >> SMTP headers section if you are using any list Unsubscribe functionality which would be using message.recipient_id and make modification accordingly.

 

Thanks

Akshay

rvnthAuthor
Level 5
January 10, 2024

Thank you @akshayanand  @parthasarathy , my smpt headers were empty and also I tried proof testing without any HTML code by keeping empty and found the same error.

 

Please adise