Unless you're (a) interested in how to make web-forms useful, and
(b) prepared to assist a fellow-linker solve a design problem,
please ignore this barely-on-topic request!

___________________

I have a problem designing a web-form.

I'm using a long succession of forms to gather survey responses.

It's another step in the long ACS constitutional process (but, despite
the ACS's wealth, I don't have access to professional support).


There are about 50 questions, all of which are optional, and they can be
accessed and responded to in any order.  So each is a separate form, all
of which are in one file.

The raw design involves the respondent having to type their
email-address every time they submit a response to a question.

A fragment showing two of the questions is here:
http://rogerclarke.com/SOS/CRWG2-CDW-TEST-220111.html


I'm trying to:
(a)  *capture the respondent's email-address once-only, and*
(b)  *use it for every subsequent response during that session*.


In the questionnaire form, I envisage using (in principle) something
like the following to access the email-address, already captured and
pre-stored, in a global variable, say $emailaddress:

     <input type="hidden" name="mail" value="$emailaddress">

and including that data in the transmission to the server.
(The server generates an email-posting to the groups.io Online Forum.
I got all of that working fine in the previous consultation round).


But I have no idea how to enable a web-page to capture and pre-store the
user's email-address in a global variable accessible by a web-form.

Searches on HTML Forms tutorial and doco sites have't helped.

I envisage something like this, as a preliminary web-form when the
person first displays the page:

  <form>
    <label for="mail">* Your E-mail Address:  </label>
       <input type="email" id="emailaddress" name="emailaddress"
              size="51" required>
    <input type = "button" name = "Remember" value = $emailaddress" />
  </form>


I imagine I need to use javascript in conjunction with the preliminary
web-form.  But I haven't been able to see a way in which I can get a
button in a web-form to call a javascript routine that can set a global
variable accessible by each of the later web-forms' input lines (and, of
course, avoid any action to transmit to the web-server).


___________________

Roger Clarke                            mailto:[email protected]
T: +61 2 6288 6916   http://www.xamax.com.au  http://www.rogerclarke.com

Xamax Consultancy Pty Ltd      78 Sidaway St, Chapman ACT 2611 AUSTRALIA

Visiting Professor in the Faculty of Law            University of N.S.W.
Visiting Professor in Computer Science    Australian National University
_______________________________________________
Link mailing list
[email protected]
https://mailman.anu.edu.au/mailman/listinfo/link

Reply via email to