Best answer

Error when adding HTML to my Zap: “The email could not be sent to Pardot. Cannot read property ‘@attributes’ of undefined.


Hi!

We’re trying to set up a Zap that will send an HTML email from Pardot whenever a new blog is posted to our Wordpress. When adding the HTML email into Zapier, we are met with this error upon testing the Zap:

“The email could not be sent to Pardot. Cannot read property ‘@attributes’ of undefined.

Zapier and Pardot blame eachother, so not much help there. I have tried to Google and troubleshoot but am hitting a wall. Any help would be greatly appreciated!!

 

 

 

icon

Best answer by Danvers 26 May 2022, 17:20

View original

This post has been closed for comments. Please create a new post if you need help or have a question about this topic.

11 replies

Userlevel 7
Badge +14

Hi @mgtms11 

Good question.

Please post detailed screenshots with how your Zap steps are configured in order for us to have more context, thanks.

 

Userlevel 7
Badge +14

@mgtms11 

Please post screenshots with how you have the Zap Step 2 fully configured, thanks.

 

Email HTML (this is just a basic Pardot template, no added or custom code):

 

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta content="text/html; charset=utf-8" http-equiv="Content-Type" /> <!-- Facebook sharing information tags --> <meta property="og:title" content=" %%subject%% " /> <title> %%subject%% </title> </head> <body bgcolor="#FAFAFA" style="-webkit-text-size-adjust: 100%; -ms-text-size-adjust: 100%; height: 100% !important; width: 100% !important; background-color: #FAFAFA; margin: 0; padding: 0;"> <style type="text/css">#outlook a { padding: 0; } .body{ width: 100% !important; -webkit-text-size-adjust: 100%; -ms-text-size-adjust: 100%; margin: 0; padding: 0; } .ExternalClass { width:100%; } .ExternalClass, .ExternalClass p, .ExternalClass span, .ExternalClass font, .ExternalClass td, .ExternalClass div { line-height: 100%; } img { outline: none; text-decoration: none; -ms-interpolation-mode: bicubic; } a img { border: none; } p { margin: 1em 0; } table td { border-collapse: collapse; } /* hide unsubscribe from forwards*/ blockquote .original-only, .WordSection1 .original-only { display: none !important; } @media only screen and (max-width: 480px){ body, table, td, p, a, li, blockquote{-webkit-text-size-adjust:none !important;} /* Prevent Webkit platforms from changing default text sizes */ body{width:100% !important; min-width:100% !important;} /* Prevent iOS Mail from adding padding to the body */ #bodyCell{padding:10px !important;} #templateContainer{ max-width:600px !important; width:100% !important; } h1{ font-size:24px !important; line-height:100% !important; } h2{ font-size:20px !important; line-height:100% !important; } h3{ font-size:18px !important; line-height:100% !important; } h4{ font-size:16px !important; line-height:100% !important; } #templatePreheader{display:none !important;} /* Hide the template preheader to save space */ #headerImage{ height:auto !important; max-width:600px !important; width:100% !important; } .headerContent{ font-size:20px !important; line-height:125% !important; } .bodyContent{ font-size:18px !important; line-height:125% !important; } .footerContent{ font-size:14px !important; line-height:115% !important; } .footerContent a{display:block !important;} /* Place footer social and utility links on their own lines, for easier access */ } </style> <table align="center" border="0" cellpadding="0" cellspacing="0" id="bodyTable" style="-ms-text-size-adjust: 100%; -webkit-text-size-adjust: 100%; background-color: #FAFAFA; border-collapse: collapse !important; height: 100% !important; margin: 0; mso-table-lspace: 0pt; mso-table-rspace: 0pt; padding: 0; width: 100% !important" width="100%"> <tbody> <tr> <td align="center" id="bodyCell" style="-webkit-text-size-adjust: 100%; -ms-text-size-adjust: 100%; mso-table-lspace: 0pt; mso-table-rspace: 0pt; height: 100% !important; width: 100% !important; border-top-width: 4px; border-top-color: #dddddd; border-top-style: solid; margin: 0; padding: 20px;" valign="top"><!-- BEGIN TEMPLATE // --> <table border="0" cellpadding="0" cellspacing="0" id="templateContainer" style="-webkit-text-size-adjust: 100%; -ms-text-size-adjust: 100%; mso-table-lspace: 0pt; mso-table-rspace: 0pt; border-collapse: collapse !important; width: 600px; border: 1px solid #dddddd;"> <tbody> <tr> <td align="center" style="-webkit-text-size-adjust: 100%; -ms-text-size-adjust: 100%; mso-table-lspace: 0pt; mso-table-rspace: 0pt;" valign="top"><!-- BEGIN PREHEADER // --> <table border="0" cellpadding="0" cellspacing="0" id="templatePreheader" style="-ms-text-size-adjust: 100%; -webkit-text-size-adjust: 100%; background-color: #FFFFFF; border-bottom-color: #CCCCCC; border-bottom-style: solid; border-bottom-width: 1px; border-collapse: collapse !important; mso-table-lspace: 0pt; mso-table-rspace: 0pt" width="100%"> <tbody> <tr style=""> <td align="left" class="preheaderContent" pardot-region="preheader_content00" style="-webkit-text-size-adjust: 100%; -ms-text-size-adjust: 100%; mso-table-lspace: 0pt; mso-table-rspace: 0pt; color: #808080; font-family: Helvetica; font-size: 10px; line-height: 12.5px; text-align: left; padding: 10px 20px;" valign="top">Use this area to offer a short teaser of your email's content. Text here will show in the preview area of some email clients.</td> <td align="left" class="preheaderContent" pardot-region="preheader_content01" style="-webkit-text-size-adjust: 100%; -ms-text-size-adjust: 100%; mso-table-lspace: 0pt; mso-table-rspace: 0pt; color: #808080; font-family: Helvetica; font-size: 10px; line-height: 12.5px; text-align: left; padding: 10px 20px 10px 0;" valign="top" width="180">Email not displaying correctly?<br> </td> </tr> </tbody> </table> <!-- // END PREHEADER --></td> </tr> <tr> <td align="center" style="-webkit-text-size-adjust: 100%; -ms-text-size-adjust: 100%; mso-table-lspace: 0pt; mso-table-rspace: 0pt;" valign="top"><!-- BEGIN HEADER // --> <table border="0" cellpadding="0" cellspacing="0" id="templateHeader" style="-ms-text-size-adjust: 100%; -webkit-text-size-adjust: 100%; background-color: #FFFFFF; border-bottom-color: #CCCCCC; border-bottom-style: solid; border-bottom-width: 1px; border-collapse: collapse !important; mso-table-lspace: 0pt; mso-table-rspace: 0pt" width="100%"> <tbody> <tr pardot-repeatable="" style=""> <td align="left" class="headerContent" pardot-region="header_image" style="-webkit-text-size-adjust: 100%; -ms-text-size-adjust: 100%; mso-table-lspace: 0pt; mso-table-rspace: 0pt; color: #505050; font-family: Helvetica; font-size: 20px; font-weight: bold; line-height: 20px; text-align: left; vertical-align: middle; padding: 0;" valign="top"><img alt="" id="headerImage" src="/images/placeholder.php?width=600&amp;height=150" style="max-width: 600px; -ms-interpolation-mode: bicubic; height: auto; outline: none; text-decoration: none; border: 0;"></td> </tr> </tbody> </table> <!-- // END HEADER --></td> </tr> <tr> <td align="center" style="-webkit-text-size-adjust: 100%; -ms-text-size-adjust: 100%; mso-table-lspace: 0pt; mso-table-rspace: 0pt;" valign="top"><!-- BEGIN BODY // --> <table border="0" cellpadding="0" cellspacing="0" id="templateBody" style="-ms-text-size-adjust: 100%; -webkit-text-size-adjust: 100%; background-color: #FFFFFF; border-bottom-color: #CCCCCC; border-bottom-style: solid; border-bottom-width: 1px; border-collapse: collapse !important; border-top-color: #FFFFFF; border-top-style: solid; border-top-width: 1px; mso-table-lspace: 0pt; mso-table-rspace: 0pt" width="100%"> <tbody> <tr pardot-repeatable="" style=""> <td align="left" class="bodyContent" pardot-region="body_content" style="-webkit-text-size-adjust: 100%; -ms-text-size-adjust: 100%; mso-table-lspace: 0pt; mso-table-rspace: 0pt; color: #505050; font-family: Helvetica; font-size: 14px; line-height: 21px; text-align: left; padding: 20px;" valign="top"> <h1 style="color: #202020 !important; display: block; font-family: Helvetica; font-size: 26px; font-style: normal; font-weight: bold; letter-spacing: normal; line-height: 26px; margin: 0; padding-bottom:10px; text-align: left">Designing Your Template</h1> <h3 style="color: #606060 !important; display: block; font-family: Helvetica; font-size: 16px; font-style: italic; font-weight: normal; letter-spacing: normal; line-height: 16px; margin: 0; padding-bottom:10px; text-align: left">Creating a good-looking email is simple</h3> Customize your template by clicking on the style editor tabs above. Set your fonts, colors, and styles. After setting your styling is all done you can click here in this area, delete the text, and start adding your own awesome content.<br> &nbsp; <h2 style="color: #404040 !important; display: block; font-family: Helvetica; font-size: 20px; font-style: normal; font-weight: bold; letter-spacing: normal; line-height: 20px; margin: 0; padding-bottom:10px; text-align: left">Styling Your Content</h2> <h4 style="color: #808080 !important; display: block; font-family: Helvetica; font-size: 14px; font-style: italic; font-weight: normal; letter-spacing: normal; line-height: 14px; margin: 0; padding-bottom:10px; text-align: left">Make your email easy to read</h4> After you enter your content, highlight the text you want to style and select the options you set in the style editor in the "<em>styles</em>" tab. Want to <a href="#" style="-webkit-text-size-adjust: 100%; -ms-text-size-adjust: 100%; color: #336699; font-weight: normal; text-decoration: underline;">get rid of styling on a bit of text</a>, but having trouble doing it? Just use the "<em>remove formatting</em>" button to strip the text of any formatting and reset your style.

 

1. Title Rendered:M...Management

 

1. Link:https://m-management/</td> </tr> </tbody> </table> <!-- // END BODY --></td> </tr> <tr> <td align="center" style="-webkit-text-size-adjust: 100%; -ms-text-size-adjust: 100%; mso-table-lspace: 0pt; mso-table-rspace: 0pt;" valign="top"><!-- BEGIN FOOTER // --> <table border="0" cellpadding="0" cellspacing="0" id="templateFooter" style="-ms-text-size-adjust: 100%; -webkit-text-size-adjust: 100%; background-color: #FFFFFF; border-collapse: collapse !important; border-top-color: #FFFFFF; border-top-style: solid; border-top-width: 1px; mso-table-lspace: 0pt; mso-table-rspace: 0pt" width="100%"> <tbody> <tr pardot-removable="" style=""> </tr> <tr style=""> <td align="left" class="footerContent" pardot-region="footer_content01" style="-webkit-text-size-adjust: 100%; -ms-text-size-adjust: 100%; mso-table-lspace: 0pt; mso-table-rspace: 0pt; color: #808080; font-family: Helvetica; font-size: 10px; line-height: 15px; text-align: left; padding: 0 20px 20px;" valign="top"><em>Copyright © %%current_year%% , All rights reserved.</em><br> <br> <strong>Our mailing address is:</strong><br> { %%organization_address%% }</td> </tr> <tr style=""> <td align="left" class="footerContent original-only" pardot-region="footer_content02" style="-webkit-text-size-adjust: 100%; -ms-text-size-adjust: 100%; mso-table-lspace: 0pt; mso-table-rspace: 0pt; color: #808080; font-family: Helvetica; font-size: 10px; line-height: 15px; text-align: left; padding: 0 20px 40px;" valign="top"><a href=" %%unsubscribe%% " style="-webkit-text-size-adjust: 100%; -ms-text-size-adjust: 100%; color: #606060; font-weight: normal; text-decoration: underline;">unsubscribe from all emails</a>&nbsp;&nbsp;&nbsp;&nbsp;</td> </tr> </tbody> </table> <!-- // END FOOTER --></td> </tr> </tbody> </table> <!-- // END TEMPLATE --></td> </tr> </tbody> </table> <br> <!-- This email was originally designed by the wonderful folks at MailChimp and remixed by Pardot. It is licensed under CC BY-SA 3.0 --> </body> </html>

 

 

 

Userlevel 7
Badge +14

@mgtms11 

Might be best to open a ticket with Zapier Support for further assistance troubleshooting this: https://zapier.com/app/get-help

Hi Troy,

I already have and was told it was a Pardot issue. When I opened a ticket with Pardot, they told me it was certainly a Zapier issue. Posting in the community is all I could think to do next. Should I open a new case?

 

 

Userlevel 7
Badge +14

@mgtms11 

Ask Zapier Support who owns the Pardot Zap app integration. (Salesforce or Zapier)

FYI: Most apps on Zapier are built and maintained by the app developers themselves, rather than by Zapier.

 

Ask Zapier Support for more detailed error logs, that you may be able to provide to Pardot/Salesforce should they be the owner of the Pardot Zap app.

Userlevel 7
Badge +9

Hey @mgtms11 so sorry for the trouble here! I do see that you have been working with our support team in regards to this issue and that my colleague Nikki said:

Troubleshooting specific code such as HTML does go beyond the boundary that our team is able to support. Our team doesn't have the resources to dig into what if any parts of the HTML are causing the trouble. 
 
I did take a look at our logs here and I wanted to share what I've found: (screenshot removed to protect personal information)
 
The tough thing is that these really don't give us much specifics aside from that Pardot didn't like the request. Your best bet may be some trial and error, or testing with another tool such as Postman to see if that may help you isolate what's causing the specific issue. 

 
I’m really sorry for the back and forth you’ve been experiencing here! I might suggest including the Pardot support team on the email thread you have going with our support team. This way, both sides can come together and get this issue sorted out for you. Best of luck!
 

Is it possible that we’re seeing this error because of a trial account? I’m in a meeting with Pardot Support and they are suggesting that this could be the case. We went through on their trial account and set up a different Zap with an Action to send a Pardot email and ran into the same error:

“The email could not be sent to Pardot. Cannot read property ‘@attributes’ of undefined.

 

 

Userlevel 7
Badge +12

Hi @mgtms11!

Being on a Zapier trial account shouldn’t have any bearing on the Zap, so I’m pretty confident that it’s not that. 

I did some digging and I found that we do have a report on an issue in the Pardot integration where using an html template causes an error. Comparing the html that our Customer Champion shared with you to the error report I’m pretty confident that it’s the same issue, so I’d say that’s what’s happening here. 

I’ve added you to the issue report, which lets our team know how many users are affected by the bug and also means that we’ll send you an email when we have an update. I can’t say when or even if that might be, and I’m sorry that you’ve not been able to make the Zapier Pardot integration work the way that you need it to. I hope that this at least gives you an answer and of course if you need any other help either the Community or our Support Team are here for you. 

 

Thank you Danvers for taking the time to look into this. When I initially reached out to Zapier Support I was met with “we don’t troubleshoot HTML” and not much to go on other than that. So I spent hours doing that myself with no luck. I hope this answer helps someone else that might experience this issue!