|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Change the value of an hidden field with radio button
Hello,
I have a form with an hidden field (submit_to). This hidden field is an email address to which the form is sent. This field is mandatory. I need that the form is sent to the email address defined with radio buttons. I have 3 radio buttons: - USA - UK - USA + UK Now, if someone selects the USA button, then the form should be sent to usa@test.com. If the UK is checked, the email should be sent to uk@test.com and if the third option is checked, then the email should be sent to both email addresses. Could you please help me? Thanks |
|
#2
|
|||
|
|||
|
RE: Change the value of an hidden field with radio button
<input type="radio" name="country" onClick="document.forms[0].action='mailto:'+document.country.value+'@test.co m'">
Something like that, though I wouldn't guess that'll work without some adjustments. I don't know about the emailing to 2 addresses unless by using a server-side script. |
![]() |
| Viewing: Codewalkers Forums > Other Technologies > Client Side Things > Change the value of an hidden field with radio button |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|