Results 1 to 2 of 2

Thread: processing form input values

  1. #1
    Junior Member
    Join Date
    Jun 2003

    processing form input values

    im making a form and im using the London Perl Mongers form processing script for processing...however im having trouble. basicaly what i want to do is have the user input some numbers in some fields and just sum those values and print them in another field (or in another page generated when the form is submitted...whichever is easiest)...can anyone help me? how can i go about doing this...i dont have much knowledge in cgi/perl...anyone have an easy way to get around this? thanks
    \"High on the waves you make for us...but not since you left have the waves come...\"

  2. #2
    Webius Designerous Indiginous
    Join Date
    Mar 2002
    South Florida
    This can be done in virtually any server side scripting out there. You can also do this using javascript which is done in the broswer side itself. Using javascript i would do this:

    (its late.. bear with me)


    <script type="text/javascript">
    function validate()
    var answer
    answer = document.myForm.firstNum.value + document.myForm.secondNum.value
    document.myForm.answer.value = answer

    <form name="myForm" action="file.html" onsubmit="return validate()">

    Enter the first number:
    <input type="text" name="firstNum">
    Enter the second number:
    <input type="text" name="secondNum">
    Your answer is:
    <script type="text/javascript">

    <input type="text" name="">
    <input type="submit" value="Send input">


    Something like that should do it.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts