Jump to content

smartzain

Members
  • Content Count

    9
  • Joined

  • Last visited

Community Reputation

0 Neutral

About smartzain

  • Rank
    Newbie
  • Birthday 11/11/1992

Previous Fields

  • Languages
    English

Contact Methods

  • MSN
    smart_zain92@hotmail.com
  • Skype
    smartzain1

Profile Information

  • Location
    karachi
  • Interests
    HTML , Javascript, QA, Graphic Designing, CSS
  1. I,m working on it but i cannot do.. so kindly help me to make a test slider
  2. I want to add these four check boxes in grand_total field but i could not do that.... will u please help me....??
  3. guyz please check this coding and tell me where is the error....
  4. <script type="text/javascript">function total_amount(){document.getElementById("grand_total").innerHTML = "";var sugar_check = 100;var milk_check = 200;var curd_check = 50;var rice_check = 250;var grand_total = "";var amount = 0;if(document.getElementById('sugar_check').checked == true){amount = sugar_check;}if(document.getElementById('milk_check').checked == true){amount = milk_check;}if(document.getElementById('curd_check').checked == true){amount = curd_check;}if(document.getElementById('rice_check').checked == true){amount = rice_check;}else{alert('Please make a selection first...! ');}document.getElementById("grand_total").innerHTML = amount;}</script> <div id="text"> <form name="myForm" action="" method="post"> <ul> <li> <input type="checkbox" name="item" id="sugar_check" /> Sugar = Rs.100</li> <li> <input type="checkbox" name="item" id="milk_check" /> Milk = 200</li> <li> <input type="checkbox" name="item" id="curd_check" /> Curd = 50</li> <li> <input type="checkbox" name="item" id="rice_check" /> Rice = 250</li> </ul> <a href="javascript:;" onclick="total_amount()">SUBMIT</a> </form></div>
  5. this is my form kindly check this.. <script type="text/javascript">function validateForm(){ if(document.getElementById("firstname").value == "") { document.getElementById("error_firstname").innerHTML = "First Name Required"; } if(document.getElementById("lastname").value == "") { document.getElementById("error_lastname").innerHTML = "Last Name Required"; } if(document.getElementById("country").value == "Select Your Country") { document.getElementById("error_country").innerHTML = "Select Country"; } if(document.getElementById("city").value == "") { document.getElementById("error_city").innerHTML = "City Requried"; } if(document.getElementById("email").value == "") { document.getElementById("error_email").innerHTML = "Email Address Required"; } if (document.getElementById("gender[0]").checked == false && document.getElementById("gender[1]").checked == false) { document.getElementById("error_gender").innerHTML = "Gender Required"; } return false;} <td style="background-color:#eeeeee;width:1000px;text-align:left;" valign="top"><h1 class="heading" >Registration Form</h1> <form name="myForm" action="registration.html" method="get" id="myForm" onsubmit="return validate();"> <table border="0" class="table"> <tr> <td>First name :*</td> <td><input type="text" name="firstname" id="firstname"/></td> </tr> <tr> <td></td> <td class="error"><div id="error_firstname"></div></td> </tr> <tr> <td>Last name :*</td> <td><input type="text" name="lastname" id="lastname" /></td> </tr> <tr> <td></td> <td class="error"><div id="error_lastname"></div></td> </tr> <tr> <td>Country :*</td> <td><select name="Country" id="country" /> <option>Select Your Country</option> <option value="United States">United States</option> <option value="United Kingdom">United Kingdom</option> </select></td> </tr> <tr> <td></td> <td class="error"><div id="error_country"></div></td> </tr> <tr> <td>City :*</td> <td><input type="text" name="city" id="city" /></td> </tr> <tr> <td></td> <td class="error"><div id="error_city"></div></td> </tr> <tr> <td>Email Address :*</td> <td><input type="text" email="emailaddress" id="email" value="" /></td> </tr> <tr> <td></td> <td class="error"><div id="error_email"></div></td> </tr> <tr> <td>Phone no :</td> <td><input type="text" name="phonenumber" value="" autocomplete="on"></td> </tr> <tr> <td valign="top">Gender :*</td> <td><input type="radio" name="gender" id="gender[0]" value="Male" /> Male <input type="radio" name="gender" id="gender[1]" value="Female"> Female</td> </tr> <tr> <td></td> <td class="error"><div id="error_gender"></div></td> </tr> <tr> <td valign="top">Like :</td> <td><input type="checkbox" name="Like" value="Yes" /> Yes <input type="checkbox" name="Like" value="No" /> No</td> </tr> <tr> <td valign="top">Addtional Request :</td> <td><textarea rows="8" cols="24"></textarea></td> </tr> <tr> <td align="right" colspan="2"><input type="submit" onclick="return validate();" value="Submit" /> <input type="reset" value="Reset" /></td> </tr> </table> </form>
  6. Hi DON Eyesterday i was working on that form i was also make an asp file and wrote this file name in action="registration.asp" but when i was click on to the submit button so no validation occured and registration.asp file download automatically... kindly tell me the right way.
  7. dude, if i do this <form name="myform" action="registration.html" method="get" id="myform" onsubmit="return validate();" > so no validation occured
  8. <td style="background-color:#eeeeee;width:1000px; text-align:left;" valign="top"><h1 class="heading">Registration Form</h1> <form name="myform" action="registration.html" method="get" id="myform" > <td align="right" colspan="2"><input type="submit" onclick="return validate();" name="submit" value="Submit" /> <input type="reset" value="Reset" /></td> Kindly tell me the right way to submit form on another page
  9. i was just make my form before two days. apply this if (document.getElementById("gender[0]").checked == false && document.getElementById("gender[1]").checked == false){document.getElementById("error_gender").innerHTML = "Gender Required";
×
×
  • Create New...