I hope I am doing this in the appropriate way. I was able to solve the problem I had yesterday and wanted to share my results with anyone else who might benefit from them.
I also wanted to thank Ultimater for being so kind in helping me.
What I was trying to do was figure out a way, using JS, to have Mailto value in a tag like this <input type=”hidden” name=”mailto” value=””> be populated with email addresses entered in other form fields by users. I hope that’s clearer than mud. Anyway, it may be sloppy, but it works.
The 2 fields in my form are called: CCEMAIL & RequesterEmail
Here is the JavaScript. I entered it into a function I was already using to validate form fields:
var ccURL = Contract.ccemail.value;
Contract.mailcc.value = ccURL;
var URL = Contract.RequesterEmail.value;
Contract.mailto.value = URL;
I called this function in the FORM tag, using onSubmit.
Here are my 2 input tags. I placed them at the bottom, just before the </form> tag.
<input type=”hidden” name=”mailto” value=””>
<input type=”hidden” name=”mailcc” value=””>