JavaScript form processing

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • abracad

    JavaScript form processing

    Hi

    Is it possible to use JavaScript to apply different actions to a form
    depending on a value within the form (eg sending form data to
    different cgi scripts depending which radio button is checked)?
  • David Dorward

    #2
    Re: JavaScript form processing

    abracad wrote:
    [color=blue]
    > Is it possible to use JavaScript to apply different actions to a form
    > depending on a value within the form (eg sending form data to
    > different cgi scripts depending which radio button is checked)?[/color]

    Possible, but unwise - it causes the script to break should JavaScript not
    be available an enabled.

    Check which script you want to use on the server, then perform an http
    redirect by sending a location header along with a suitable status code.

    --
    David Dorward <http://dorward.me.uk/>

    Comment

    Working...