Javascript Help (Dynamically inserting form hidden field value with JS stopped working)

Hey there,
I’ve been using the follow code to dynamically insert a CMS value into a hidden form field so I can send a specific email to that subscriber, based on that form field data.

This lives in the “Before < / body>” custom code for my Articles template.

This was working like a dream for a while, inserting the Lead Magnet: Drip Tag value into that hidden field and passing it along over to Drip when the form was submitted.

But now it’s not. I have no idea what changed.

Can anyone spot the issue?

Here’s my share link: Webflow - Salesographer

You’ll see the issue in question on the Articles collection template page, in this form:

And, just as a sanity check, this seems to be set up correctly, to me:

Anyone have any ideas?

1 Like