Latest Tutorials| Questions and Answers|Ask Questions?|Site Map



Home Answers Viewqa JSP-Servlet please help me.

Have Programming Question? Ask it here!
 
 
 


S.Trinath Subudhi
please help me.
3 Answer(s)      3 years and 6 months ago
Posted in : JSP-Servlet


Please send me the validation of this below link.

the link is http://www.roseindia.net/answers/viewqa/JSP-Servlet/9584-JSP-Servlet-Search-and-Edit.html

Thanks Trinath


Advertisement
View Answers

March 3, 2011 at 4:15 PM


Please visit the following link:

GWT Tutorials



March 3, 2011 at 4:16 PM


sorry for the above post.



March 3, 2011 at 4:55 PM


Javascript form validation

<html>
<script>
function checkName(text) {
if(isNaN(text)){ return 1;}
else{alert("Please enter a valid name. The only charachters accepted are A - Z and a - z");return 0;}
}
function checkAddress(text) {
if(isNaN(text)){ return 1;}
else{alert("Please enter a valid address. The only charachters accepted are A - Z and a - z");return 0;}
}

function validate(){
    if(document.form.name.value == ""){
        alert ( "Please enter name." );
        document.form.name.focus();
        return false;
    }
     if (checkName(document.form.name.value)==false){
        document.form.name.focus();
        document.form.name.value == ""
        return false
      }
     if (document.form.address.value == ""){
        alert ( "Please enter address." );
        document.form.address.focus();
        return false;
     }
     if (checkAddress(document.form.address.value)==false){
        document.form.address.focus();
        document.form.address.value == ""
        return false
     }
     if(document.form.contactNo.value == ""){
        alert ( "Please enter contact No." );
        document.form.contactNo.focus();
        return false;
     }
        var con=document.form.contactNo.value;
        var ex = new RegExp(/^\d+$/);
        var t=ex.test(con);
        if(!t){
        alert("Enter only Number .");
        document.form.contactNo.focus();
        return false;
      }
   }  
</script>
<form name="form" method="post" onsubmit="return validate();">
<table>
<tr><td>Enter Name</td><td><input type="text" name="name"></td></tr>
<tr><td>Enter Address</td><td><input type="text" name="address"></td></tr>
<tr><td>Enter Contact No</td><td><input type="text" name="contactNo"></td></tr>
<tr><td></td><td><input type="submit" value="Add" name="button"></td></tr>
</table>
</form>
</html>


Related Tutorials/Questions & Answers:
Advertisements
 

 

 

DMCA.com