Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
en:create:inputs-single [17.03.2021 20:49] – [Selection and Dropdown] sophia.schaueren:create:inputs-single [17.03.2021 20:52] (current) – [Extended Selection and Text] sophia.schauer
Line 66: Line 66:
 <code javascript> <code javascript>
 <script type="text/javascript"> <script type="text/javascript">
-QuestionSelect.LinkSelect2Text("AU01_12", "TE01_01");+S2Selection.linkOptionToInput("AU01_12", "TE01_01");
 </script> </script>
 </code> </code>
  
-The first parameter in the function `QuestionSelect.LinkSelect2Text()` specifies the HTML ID of the radio button or checkbox, in the example the option with the code 12 in question AU01 (an extended selection that allows multiple choice selection). The second parameter is the HTML identifier of the corresponding text input (here the first input in question TE01).+The first parameter in the function `S2Selection.linkOptionToInput()` specifies the HTML ID of the radio button or checkbox, in the example the option with the code 12 in question AU01 (an extended selection that allows multiple choice selection). The second parameter is the HTML identifier of the corresponding text input (here the first input in question TE01).
  
 The function `prepare_input ()` (in the PHP code at the top of the page) would have been used in this example for the identifier ''TE01_01''. The function `prepare_input ()` (in the PHP code at the top of the page) would have been used in this example for the identifier ''TE01_01''.
Line 78: Line 78:
 <code javascript> <code javascript>
 <script type="text/javascript"> <script type="text/javascript">
-new S2Selection.LinkSelect2Text("AU01_12", "TE01_01"); +S2Selection.linkOptionToInput("AU01_12", "TE01_01"); 
-new S2Selection.LinkSelect2Text("AU01_16", "TE01_02"); +S2Selection.linkOptionToInput("AU01_16", "TE01_02"); 
-new S2Selection.LinkSelect2Text("AU01_221", "TE01_03");+S2Selection.linkOptionToInput("AU01_221", "TE01_03");
 </script> </script>
 </code> </code>
en/create/inputs-single.txt · Last modified: 17.03.2021 20:52 by sophia.schauer
 
Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Share Alike 4.0 International
Driven by DokuWiki