Lead Capture Tools

balabanov
投稿者

Ignore a specific non-Hubspot form from being collected

解決

Hey there!

 

Is there an option to keep the "Collect data from website forms" option enabled, but to somehow mark a few forms to be skipped by the Hubspot form tracking JS code?

I vaguely recall there was some markup feature, but, for the life of me, I can't find any evidence to that.

3件の承認済みベストアンサー
balabanov
解決策
投稿者

Ignore a specific non-Hubspot form from being collected

解決

Well, while we're at it and I don't have a blog to post it to, there is a way to exclude a specific form from being collected.

 

What you need to do is add the following code to it:

<label for="amex" style="display:none">AMEX</label>
<input type="hidden" name="amex" required="" value="" id="amex">

HS JS tracking code will deem your form as one that contains sensitive data and will ignore it. 

元の投稿で解決策を見る

ianpetzer
解決策
参加者

Ignore a specific non-Hubspot form from being collected

解決

I've gone and looked at the source for collected-forms.js

They check for the following labels:

, s = ["credit card", "card number", "expiration", "expiry", "ccv", "cvc", "cvv", "secure code", "mastercard", "american express", "amex"]

and the following for names:
, c = ["cc-num", "cc-number"]

 

in a function called isSensitive which is used in a function called rejectIfAnyFieldSensitive

 

So I've managed to get the form to not submit with the following markup:

 

    <label for="cc-num" class="hidden">credit card HubspotCollectedFormsWorkaround https://community.hubspot.com/t5/APIs-Integrations/How-to-stop-collected-forms-from-collecting-a-form/m-p/299172#M28102</label>
    <input name="cc-num" class="hidden" required="" value="HubspotCollectedFormsWorkaround" id="cc-num">

Would be great if this could be added to the documentation 

 

元の投稿で解決策を見る

garrett9
解決策
メンバー

Ignore a specific non-Hubspot form from being collected

解決

I noticed that when you specify in HubSpot to collect info from non-HubSpot forms, it attempts to add the script collectedforms.js to your website. However, before doing so, it checks to see if it's already installed by using the document.getElementById method where the ID is CollectedForms-1234 (1234 is the ID at the end of your tracking script). Therefore, if you simply put any HTML element on your page with that ID, such as

<span id="CollectedForms-1234"></span>, it won't install the collectedforms.js file, meaning it also won't collect information on your non-HubSpot forms. While still a hack, it doesn't force you to change your forms, and it's much easier to conditionally add it based on where the user is in your app. Just be sure that this element exists statically on your website, and isn't loaded dynamically.

元の投稿で解決策を見る

38件の返信
ianpetzer
参加者

Ignore a specific non-Hubspot form from being collected

解決

@parinsanghvi I posted a workaround higher up in this thread. https://community.hubspot.com/t5/Lead-Capture-Tools/Ignore-a-specific-non-Hubspot-form-from-being-co...

 

Simply include the hidden label and inout field into your form and Hubspot will ignore it.

JGood
投稿者

Ignore a specific non-Hubspot form from being collected

解決

Hi there....  does your "fix" still apply?  We are having big issues with this where hubspot forms are pulling data out of our web app that our customers are using.  I just wanted to find out if this fix still works.  Thanks so much!

 

 

0 いいね!
ianpetzer
参加者

Ignore a specific non-Hubspot form from being collected

解決

Hiya,

 

My fix is still working for me. Your mileage may vary 🙂

ianpetzer
参加者

Ignore a specific non-Hubspot form from being collected

解決

Hi @jennysowyrda ,

 

Saying that hubspot has to crawl for all forms on a site, so there is no way to turn it off for certain pages or forms doesnt make any sense.

 

They could easily exclude forms that have a particular data attribute or class on the form.

It doesnt make any sense for Hubspt to crawl all the forms and not have a way to mark some as private. This is resulting in a violation of GDPR as forms containing private information are being submitted

jennysowyrda
コミュニティーマネージャー
コミュニティーマネージャー

Ignore a specific non-Hubspot form from being collected

解決

Hi @ianpetzer,

 

Thank you for reaching out. It will be your responsibility to ensure your forms comply with the law. I would recommend partnering with your legal team to ensure your forms are GDPR compliant. Additionally, HubSpot does not accept sensitive information through our forms. Please ensure that all form fields are compliant with our terms of use.

 

Thank you,
Jenny

0 いいね!
ChrisMoyer
参加者

Ignore a specific non-Hubspot form from being collected

解決

They aren't your forms. They're our forms. You're effectively saying "do not allow HubSpot code on any site if you want it to be GDPR compliant".

 

So your software is not compliant with any privacy laws. Good to know.

0 いいね!
ianpetzer
参加者

Ignore a specific non-Hubspot form from being collected

解決

Hi @jennysowyrda ,

 

0ur forms are GDPR compliant. The problem is this: 

 

1) A site include Hubspot collected-forms.js which causes all forms to be collected

2) On 01/29 you sadi that you cannot specify which forms to be collected, and I quote: "Because non-HubSpot forms requires HubSpot to crawl for all of the forms on your site there is no way to turn it off for certain pages or forms. :

3) This means that Hubspot is collecting sensitive data such as passport information, date of birth and address

4) Based on the workaround suggested by @balabanov , I have read through the source code and posted more information about how you can block the submission of forms by adding a fake input field with a specified name or label

5) It is up to Hubspot to add functionality to block the collection of certain forms or at least add documentaiton on how to block form collection using the workaroudn suggested above.

6) Right now, the collection of forms is blocked by the following labels:  ["credit card", "card number", "expiration", "expiry", "ccv", "cvc", "cvv", "secure code", "mastercard", "american express", "amex"]

7) As you can see this is not an exahaustive list of sensitive information. For example addresses and passport numbers and date of births are not considered sensitive

😎 The current collected-forms.js implementaiton is flawed because it is not documented how to label/name the sensitve form fields to block submission without reading the source code and the list is not comprehensive enough. 

muhammed
メンバー

Ignore a specific non-Hubspot form from being collected

解決

is still no option to ignore some forms from the site?

balabanov
解決策
投稿者

Ignore a specific non-Hubspot form from being collected

解決

Well, while we're at it and I don't have a blog to post it to, there is a way to exclude a specific form from being collected.

 

What you need to do is add the following code to it:

<label for="amex" style="display:none">AMEX</label>
<input type="hidden" name="amex" required="" value="" id="amex">

HS JS tracking code will deem your form as one that contains sensitive data and will ignore it. 

KNakamura2
参加者

Ignore a specific non-Hubspot form from being collected

解決

make sure to add a value="SOMETHING" to the field, since required="" is added if there's no value it will break in chrome as the can't be focused (its hidden), so the answer below is better.

 

https://stackoverflow.com/questions/22148080/an-invalid-form-control-with-name-is-not-focusable

 

Sorry this only happened because we had removed type="hidden". Our bad!

0 いいね!
ianpetzer
参加者

Ignore a specific non-Hubspot form from being collected

解決

This workaround from @balabanov didn;t work for me but I managed to get a variation of it working for me

 

.hidden {
  display: none;
}

<label for="credit-card" class="hidden">HubspotCollectedFormsWorkaround https://community.hubspot.com/t5/APIs-Integrations/How-to-stop-collected-forms-from-collecting-a-form/m-p/299172#M28102</label>
   
<input name="credit-card" class="hidden" required="" value="HubspotCollectedFormsWorkaround" id="credit-card">
0 いいね!
ianpetzer
参加者

Ignore a specific non-Hubspot form from being collected

解決

Actually that doesnt work in our produciton environment.

 

Still unable to block form submission for forms with private info 😞

0 いいね!
ianpetzer
解決策
参加者

Ignore a specific non-Hubspot form from being collected

解決

I've gone and looked at the source for collected-forms.js

They check for the following labels:

, s = ["credit card", "card number", "expiration", "expiry", "ccv", "cvc", "cvv", "secure code", "mastercard", "american express", "amex"]

and the following for names:
, c = ["cc-num", "cc-number"]

 

in a function called isSensitive which is used in a function called rejectIfAnyFieldSensitive

 

So I've managed to get the form to not submit with the following markup:

 

    <label for="cc-num" class="hidden">credit card HubspotCollectedFormsWorkaround https://community.hubspot.com/t5/APIs-Integrations/How-to-stop-collected-forms-from-collecting-a-form/m-p/299172#M28102</label>
    <input name="cc-num" class="hidden" required="" value="HubspotCollectedFormsWorkaround" id="cc-num">

Would be great if this could be added to the documentation 

 

BDevilla7
メンバー

Ignore a specific non-Hubspot form from being collected

解決

Same issue, we do not want to track our Job Application Form in this page for instance (https://www.ducenit.com/jobs/system-engineer-sr-system-engineer-chennai/)

 

Form identifiers

#sjb-application-form, .jobpost-form

 

 

0 いいね!
RThomas6
参加者

Ignore a specific non-Hubspot form from being collected

解決

I just ended up disconnecting non-hubspot forms to use for employment forms and anything not related to lead generation.  Then used HubSpot forms for lead gen. I'm not sure this is feasible for everyone, but I will say there are definitely some big advantages to doing this.  

 

For example, using HubSpot forms, its native so you can capture the cookie and more information with hidden fields and made it a lot of easier to automate workflows for both entry of information and moving leads through the pipeline. 

 

Being native and capturing cookies, you get a lot better data on source of lead and their behavior on your website, such as user path, pageviews.  This is helpful in many ways and overall you end up with better analytics and reporting. 

 

I was originally somewhat resistant to doing this but was advised by several people including a Diamond partner and believe it was an excellent move. 

0 いいね!
myktra
参加者

Ignore a specific non-Hubspot form from being collected

解決

With all due respect and appreciation for the solutions proposed here and the folks who have taken the time to explore them...

 

If I am a software developer integrating Live Chat (and only Live Chat) into my custom application that happens to have at least one <form> on their site – and let's face it, that's pretty much ANY custom web application – and my company also maintains a separate website using HubSpot forms and Live Chat that our web team needs to make things happen, I have no choice but to implement these hacks in my custom application.

 

As a developer I should not have to modify my central forms engine to accommodate these hacks, further tying my implementation to the HubSpot CRM.

 

DO NOT ASSUME I WANT TO SHARE ALL OF MY USER SUBMITTED DATA WITH YOU EVERYWHERE I INTEGRATE YOUR TOOLS.

 

The tracking script should have a configuration *option* that enables the automatic form data collectors. The global setting should simply allow the collectors to run, if opted in to by the person who places the script in their code/site.

 

In summary:

 

Opt In = YAY!

Opt Out + Insufficent Hacks = BOO!

 

This seems extremely easy to do, HubSpot...can we please make this happen?

 

Thank you very much in advance.

vserranoh
参加者

Ignore a specific non-Hubspot form from being collected

解決

Can't agree more on this!!! Hubspot we need this.

Thanks for your input 👏

ianpetzer
参加者

Ignore a specific non-Hubspot form from being collected

解決

Hi @balabanov 

 

Does this technique still work for you? It doesnt seem to work for me.

 

I've also noticed that since August 2019, Hubspot collected forms is now collecting dynamically creating forms in contravention of their documenation here: https://knowledge.hubspot.com/forms/use-non-hubspot-forms