I have a form with two inputs. The first one is a regular text input. The second one is a text inpu side by side with a dropdown menu list.
Once the first input is entered, the user should enter a number into the second input. The second input is essentially a sublist of numbers available under the first selected input number (think of it as a multidimensional array).
Once the onFocus or onChange is set to the second input I want to execute a the onfocus/onChange JavaScript functions and make them run a perl script. The results of the perl script should populate the dropdown list - so the user essentially will be able to select or type in the number they wish to choose.
I found this in order to make a call to a PHP function - but my function accepts only one variable and after I modified it I get or the default result or `No function arguments'
What would be the right way to execute a perl script from a JS function and then get the perl results and populate in the HTML? (I know it is broad, but a direction would be nice, and example would be great)