Jump to content

How Do I Make a Checkbox Be Selected By Default On Contact Form From Link

Recommended Posts

Site URL: https://rawperformance-gym.co.uk/contact-us-2

Hi people. (this doesn't have to do with gdpr/consent by the way) I have a client that wants checkboxes on the url to be pre selected based on a link the person clicks on the homepage. For context on the home page there is Weight loss, muscle growth, physique development and Life-long health. is there a way to create a link that when someone clicks a button it takes them to the contact page above where the relevant checkbox is already selected https://rawperformance-gym.co.uk/contact-us-2 (if not is there a way for me to create 4 contact pages and just have the individual contact page have the category pre selected?

I really Appreciate your help 🙂 

Link to comment
1 hour ago, Daniel01462 said:

I have a client that wants checkboxes on the url to be pre selected based on a link the person clicks on the homepage.

If you are trying to track the referrals to the form (which link they clicked) you can do this with a Hidden Form Field in the contact Form Block.

 

Improve your online store with our extensions.
About: Squarespace Circle Leader since 2017. I value honesty, transparency, appreciation and great design ♥.
Work: Squarespace Developer and founder of SF Digital, building the features Squarespace didn't include™.
Content: Links in my posts may refer to SF Digital products or may be affiliate links.

Buy me a coffee

Link to comment
29 minutes ago, paul2009 said:

If you are trying to track the referrals to the form (which link they clicked) you can do this with a Hidden Form Field in the contact Form Block.

 

Thankyou, so based on this do you know how i can make it so the specific checkbox is automatically selected based on where the source came from? As i cant find options to do that and dont know any code. i.e Clicked the weight loss picture gets sent to the contact form and the weight loss option is already selected

Link to comment
2 hours ago, Daniel01462 said:

Thankyou, so based on this do you know how i can make it so the specific checkbox is automatically selected based on where the source came from?

It wouldn't check a checkbox, but it would tell you which link they used when you receive the forum submission. To generate the information, you'd add some text to the end of the link that you add, as described in the guide. If it isn't clear, please post back.

Improve your online store with our extensions.
About: Squarespace Circle Leader since 2017. I value honesty, transparency, appreciation and great design ♥.
Work: Squarespace Developer and founder of SF Digital, building the features Squarespace didn't include™.
Content: Links in my posts may refer to SF Digital products or may be affiliate links.

Buy me a coffee

Link to comment
  • 2 weeks later...

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.