Javascript form validation

Discussion in 'QnA (read only)' started by jugaaru, Dec 6, 2004.

Thread Status:
Not open for further replies.
  1. jugaaru

    jugaaru New Member

    Joined:
    Oct 1, 2003
    Messages:
    8
    Likes Received:
    0
    Trophy Points:
    0
    HI
    I have to validate a form using javascript.
    name , address credit card no etc.
    Any websites for this script.

    Thnaks
     
  2. prashantisonline

    prashantisonline Super Natural

    Joined:
    Dec 7, 2004
    Messages:
    24
    Likes Received:
    0
    Trophy Points:
    0
    Location:
    Jaipur
    example

    Hi,

    firstly, make you form tag like this:

    <form name="frm1" onsubmit="eval_form()">
    now, name all fields like this:

    <input type="text" name="credit_card">

    under <script lang="jscript"> tag, put function like this:

    function eval_form()
    {
    if not document.frm1.credit_card==""()
    {
    frm1.submit
    }
    }

    You may write any code you like here.

    there could be some script err.
    site for j scripts is:
    scriptworld.com

    bye
     
  3. amitpagarwal

    amitpagarwal New Member

    Joined:
    Oct 9, 2004
    Messages:
    46
    Likes Received:
    0
    Trophy Points:
    0
  4. Deep

    Deep Version 2.0

    Joined:
    Jan 23, 2004
    Messages:
    977
    Likes Received:
    0
    Trophy Points:
    0
    Location:
    Mumbai
Thread Status:
Not open for further replies.

Share This Page