Jump to content

Hidden field form error

Recommended Posts

Posted

Site URL: https://www.nguyencaonguyen.com/abstracts

I'm trying to send along the image url through the form submission to email, but the SQF_ variable is always blank.  I've added some javacript to the page, and through the developer tools in the browser I can see the value I changed, but when I receive the email it is still blank.

<script>
  window.addEventListener('load', function() {
  const hiddenFieldValue = document.querySelector('input[name="SQF_ART"]');
  hiddenFieldValue.value = 'https://images.squarespace-cdn.com/content/v1/6731707e44f294311fe92329/52b59d95-4a66-4afa-a784-183af38858fc/IMG_5075.jpg';
  alert(hiddenFieldValue.value);
   });
</script>

image.thumb.png.c71ec08dc56ded204224c9fbb99d82fb.png

  • Replies 2
  • Views 142
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Posted Images

Posted

ooh right, on the Abstracts page https://www.nguyencaonguyen.com/abstracts

you can click on the first image (the green one) and it opens a contact-1 page

 

lately, I've tried passing the url as part of the query string

https://www.nguyencaonguyen.com/contact-1?SQF_ART=images.squarespace-cdn.com%2Fcontent%2F6731707e44f294311fe92329%2F387d9a8a-d4f1-42c6-8073-d155278dbd29%2Flush.jpg%3Fcontent-type%3Dimage%2Fjpeg

but I get the error  "Form submission failed. Review the following information: ART.

Create an account or sign in to comment

You need to be a member in order to leave a comment


×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.