<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Cannot set a custom error message in Lead Capture Tools</title>
    <link>https://community.hubspot.com/t5/Lead-Capture-Tools/Cannot-set-a-custom-error-message/m-p/735798#M8533</link>
    <description>&lt;P&gt;I have created a project on GitHub that shows how to create custom form field validations using JavaScript (without jQuery) for those interested. See&amp;nbsp;&lt;A href="https://github.com/birdmeister/hubspot-form-validation" target="_blank"&gt;https://github.com/birdmeister/hubspot-form-validation&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;Any remarks, corrections and additions are more then welcome.&lt;/P&gt;</description>
    <pubDate>Fri, 30 Dec 2022 11:17:40 GMT</pubDate>
    <dc:creator>birdman</dc:creator>
    <dc:date>2022-12-30T11:17:40Z</dc:date>
    <item>
      <title>Cannot set a custom error message</title>
      <link>https://community.hubspot.com/t5/Lead-Capture-Tools/Cannot-set-a-custom-error-message/m-p/735161#M8521</link>
      <description>&lt;P&gt;I am trying to set a custom error message on a form but so far unsuccessful.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have created a HubSpot form, set as raw HTML, embedded it on page (using hbspt.forms.create()), and added custom field validators in JavaScript that are correctly being registered with a callback function and triggered. All this works.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When a specific validation is false, how do I set a custom error message?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The method setCustomValidity("error message") does not seem to work, nor does 'textContent'.&lt;/P&gt;</description>
      <pubDate>Wed, 28 Dec 2022 13:48:31 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/Lead-Capture-Tools/Cannot-set-a-custom-error-message/m-p/735161#M8521</guid>
      <dc:creator>birdman</dc:creator>
      <dc:date>2022-12-28T13:48:31Z</dc:date>
    </item>
    <item>
      <title>Re: Cannot set a custom error message</title>
      <link>https://community.hubspot.com/t5/Lead-Capture-Tools/Cannot-set-a-custom-error-message/m-p/735276#M8522</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/100896"&gt;@birdman&lt;/a&gt;, hope you are doing well!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I have found &lt;A href="https://community.hubspot.com/t5/HubSpot-Ideas/Customize-Error-Message-in-Forms/idi-p/291693" target="_blank" rel="noopener"&gt;this thread&lt;/A&gt; with several options you can try to accomplish your goal.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Hope this helps,&lt;/P&gt;
&lt;P&gt;Diana&lt;/P&gt;</description>
      <pubDate>Wed, 28 Dec 2022 18:25:42 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/Lead-Capture-Tools/Cannot-set-a-custom-error-message/m-p/735276#M8522</guid>
      <dc:creator>DianaGomez</dc:creator>
      <dc:date>2022-12-28T18:25:42Z</dc:date>
    </item>
    <item>
      <title>Re: Cannot set a custom error message</title>
      <link>https://community.hubspot.com/t5/Lead-Capture-Tools/Cannot-set-a-custom-error-message/m-p/735454#M8528</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/482122"&gt;@EDia&lt;/a&gt;&amp;nbsp;- I have seen the article before but contains dead links. Do you know the solution? Best Martin&lt;/P&gt;</description>
      <pubDate>Thu, 29 Dec 2022 09:40:18 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/Lead-Capture-Tools/Cannot-set-a-custom-error-message/m-p/735454#M8528</guid>
      <dc:creator>birdman</dc:creator>
      <dc:date>2022-12-29T09:40:18Z</dc:date>
    </item>
    <item>
      <title>Re: Cannot set a custom error message</title>
      <link>https://community.hubspot.com/t5/Lead-Capture-Tools/Cannot-set-a-custom-error-message/m-p/735476#M8529</link>
      <description>&lt;P&gt;When looking at the form customization code (see&amp;nbsp;&lt;A href="https://legacydocs.hubspot.com/docs/methods/forms/advanced_form_options" target="_blank"&gt;https://legacydocs.hubspot.com/docs/methods/forms/advanced_form_options&lt;/A&gt;), I see the option to change error messages. But how does this work for custom validations?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;For example, I have a text input field, and there are 4 different validations it needs to pass. The error message that needs to be displayed is dependent on the specific validation.&lt;/P&gt;</description>
      <pubDate>Thu, 29 Dec 2022 10:55:37 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/Lead-Capture-Tools/Cannot-set-a-custom-error-message/m-p/735476#M8529</guid>
      <dc:creator>birdman</dc:creator>
      <dc:date>2022-12-29T10:55:37Z</dc:date>
    </item>
    <item>
      <title>Re: Cannot set a custom error message</title>
      <link>https://community.hubspot.com/t5/Lead-Capture-Tools/Cannot-set-a-custom-error-message/m-p/735533#M8530</link>
      <description>&lt;P&gt;Hi Martin, thanks for letting me know, however when I go there the &lt;A href="https://legacydocs.hubspot.com/docs/methods/forms/advanced_form_options" target="_blank" rel="noopener"&gt;first link is this one&lt;/A&gt;, and works fine. Could you double-check?&amp;nbsp;This will be the option available at the moment.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;About the second one and third one that are the same one, you are right, those are no longer in the Marketplace for that reason you see a broken page.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Hope this helps clarify.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best,&lt;/P&gt;
&lt;P&gt;Diana&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 29 Dec 2022 14:04:42 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/Lead-Capture-Tools/Cannot-set-a-custom-error-message/m-p/735533#M8530</guid>
      <dc:creator>DianaGomez</dc:creator>
      <dc:date>2022-12-29T14:04:42Z</dc:date>
    </item>
    <item>
      <title>Re: Cannot set a custom error message</title>
      <link>https://community.hubspot.com/t5/Lead-Capture-Tools/Cannot-set-a-custom-error-message/m-p/735550#M8531</link>
      <description>&lt;P&gt;Hello Diane, the first link is all known to me and does not provide a solution to the challenge I am having. Thx anyway&lt;/P&gt;</description>
      <pubDate>Thu, 29 Dec 2022 14:51:26 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/Lead-Capture-Tools/Cannot-set-a-custom-error-message/m-p/735550#M8531</guid>
      <dc:creator>birdman</dc:creator>
      <dc:date>2022-12-29T14:51:26Z</dc:date>
    </item>
    <item>
      <title>Re: Cannot set a custom error message</title>
      <link>https://community.hubspot.com/t5/Lead-Capture-Tools/Cannot-set-a-custom-error-message/m-p/735798#M8533</link>
      <description>&lt;P&gt;I have created a project on GitHub that shows how to create custom form field validations using JavaScript (without jQuery) for those interested. See&amp;nbsp;&lt;A href="https://github.com/birdmeister/hubspot-form-validation" target="_blank"&gt;https://github.com/birdmeister/hubspot-form-validation&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;Any remarks, corrections and additions are more then welcome.&lt;/P&gt;</description>
      <pubDate>Fri, 30 Dec 2022 11:17:40 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/Lead-Capture-Tools/Cannot-set-a-custom-error-message/m-p/735798#M8533</guid>
      <dc:creator>birdman</dc:creator>
      <dc:date>2022-12-30T11:17:40Z</dc:date>
    </item>
    <item>
      <title>Re: Cannot set a custom error message</title>
      <link>https://community.hubspot.com/t5/Lead-Capture-Tools/Cannot-set-a-custom-error-message/m-p/735831#M8534</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/100896"&gt;@birdman&lt;/a&gt;&amp;nbsp;&lt;span class="lia-unicode-emoji" title=":smiling_face_with_smiling_eyes:"&gt;😊&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;¡Fantastic! Thanks for sharing&amp;nbsp;&lt;span class="lia-unicode-emoji" title=":smiling_face_with_smiling_eyes:"&gt;😊&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best,&lt;/P&gt;
&lt;P&gt;Diana&lt;/P&gt;</description>
      <pubDate>Fri, 30 Dec 2022 13:52:05 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/Lead-Capture-Tools/Cannot-set-a-custom-error-message/m-p/735831#M8534</guid>
      <dc:creator>DianaGomez</dc:creator>
      <dc:date>2022-12-30T13:52:05Z</dc:date>
    </item>
  </channel>
</rss>

