Sending the value of a variable using jQuery checkbox

Issues related to forms.
Post Reply
Astro
 
 
Posts: 50
Joined: Mon Jul 07, 2014 6:38 pm

Sending the value of a variable using jQuery checkbox

Post by Astro » Wed Jan 10, 2018 4:14 am

Hello,
I built a form that includes several jQuery checkboxes. One of them needs to send the value of a variable through the form submit email.
I use this for the label/value and the checkbox label looks perfect:

Code: Select all

Upgrade to FGPT 6.0 - $<span id='AF60_Length'></span>
You can see it here (the "Upgrade to FGPT 6.0 - $102.00" checkbox) https://publicmissiles.com/Advanced60.aspx

The span id is defined by it's counterpart .innerhtml:

Code: Select all

document.getElementById("AF60_Length").innerHTML = AF_Length.toFixed(2)
The problem is that the value does not come through with the other form data, only the text string:
optionFGPT60=Upgrade to FGPT 6.0 - $<span id='AF60_Length'></span>

If this will not work directly, what is the work-around for passing the variable value to the form data?

Thanks!

User avatar
Pablo
 
Posts: 20091
Joined: Tue Mar 28, 2006 12:00 pm
Location: Europe
Contact:

Re: Sending the value of a variable using jQuery checkbox

Post by Pablo » Wed Jan 10, 2018 7:11 am

I'm sorry I cannot help you with custom code.
However HTML forms only send values of the form elements, no other data.
http://www.w3.org/TR/html401/interact/forms.html

Astro
 
 
Posts: 50
Joined: Mon Jul 07, 2014 6:38 pm

Re: Sending the value of a variable using jQuery checkbox

Post by Astro » Thu Jan 11, 2018 5:46 am

Thanks anyway.

BTW, I love WB12.

---Frank

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest