473,406 Members | 2,549 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

html validation before submitting form

How can I check validation before submitting the form.

Expand|Select|Wrap|Line Numbers
  1.  
  2.     </script>
  3. </head>
  4. <body dir="rtl">
  5. <form name="form1" action="pay.php" method="post">
  6. <table align="center" cellpadding="0" cellspacing="0" width="100%">
  7. <tbody>
  8. <tr>
  9. <td>
  10. <table class="InputTable" align="center" cellpadding="0" cellspacing="0">
  11. <tbody>
  12. <tr>
  13. <td>
  14. <table class="MainTable" align="center" cellpadding="1" cellspacing="5" height="153" width="421">
  15. <tbody>
  16. <tr class="HeaderTr">
  17. <td colspan="2" align="center" height="30px"><span class="HeaderText">اطلاعات پرداخت</span></td></tr>
  18. <tr class="RowF">
  19. <td class="LabelTd"><span>نام و نام خانوادگی :</span></td>
  20.  
  21. <td><input name="Name" class="textbox" type="text" /><font color="#ff0000" size="1">*</font></td></tr>
  22. <tr class="RowZ">
  23. <td class="LabelTd"><span>مبلغ پرداختی :</span></td>
  24. <td>                                    <input name="Amount" class="textbox" onkeyup="data_change(this)" type="text" /> <font size="1"><font color="#ff0000">*</font> </font><font size="1">ریال</font></td></tr>
  25. <tr class="RowF">
  26. <td class="LabelTd"><span>روش ارسال  : </span></td>
  27. <td><select name="Title" class="combobox">
  28. <option>از طريق شركت پست </option>
  29. <option>ارسال با باربري</option>
  30. <option>ارسال رايگان</option>
  31. <option>پرداخت  هزينه پست درب منزل</option></select>                                    </td></tr>
  32. <tr class="RowZ">
  33. <td class="LabelTd">
  34.                                         شماره موبايل<span> :</span></td>
  35. <td>                                    <input name="Email2" class="textbox" type="text" /><font size="1"><font color="#ff0000">*</font> </font><span class="comment">جهت ارسال رسيد سفارش</span></td></tr>
  36. <tr class="RowF">
  37. <td class="LabelTd">
  38.                                         آدرس دقيق پستي <span>:</span></td>
  39. <td>
  40. <p>                                    <input name="Email" class="textbox" type="text" /><font size="1"><font color="#ff0000">*</font> </font><span class="comment">جهت ارسال بسته</span></p></td></tr>
  41. <tr class="RowZ">
  42. <td colspan="2" align="center" height="30px"><font size="1"><font color="#ff0000">*</font> <font color="#ff0000"></font> بايد پر شود </font><font size="2"><font color="#0000ff"> </font></font><font size="2"><font color="#0000ff"></font></font><font size="1"> <font color="#0000ff"><font size="2"></font>&nbsp;</font> </font><br />
  43. <input class="button" name="PayRequestButton" value="پرداخت" type="submit" /></td></tr></tbody></table>                            </td></tr></tbody></table></td></tr></tbody></table>
  44. <pre>    </pre></center></form>
  45.  
  46.  
  47.  
  48. </body>
  49. </html>
Jan 14 '13 #1
3 1529
Please use showing the location of the new validation codes and how to use the codes say thanks
Jan 14 '13 #2
Anas Mosaad
185 128KB
Create a JS function that returns a boolean (i.e. named validate). Add onsubmit="return validate()" to the form.
Jan 14 '13 #3
hello
plz end me how use validation codes
Jan 15 '13 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: MarkAurit | last post by:
I have a requirement to validate some html at approx the ie6 level. The validation cant take place use a web control, but must be done in an event such as post back. Does anyone know of ideally...
12
by: Nalaka | last post by:
Hi, I suddenly started getting a lot of errors from html validation (some CSS) so I followed the following instructions to disable it. If you'd rather not have these types of HTML validation...
8
by: goldtech | last post by:
Newbie esp about html validation - seems like something to strive for. Yet many pages even "enterprise" corporate type pages do not validate, yet seem to display well on most browsers. Two...
10
by: NikitaTheSpider | last post by:
Hi all, I would like to announce the alpha release of a service that does bulk/batch HTML validation, link checking and more. During alpha testing, the service is free -- I need people to try this...
1
by: Tatyana | last post by:
Hi All, I have a question regarding validation with XHTML on ASP.Net websites. Our site is built on ASP.NET 2.0 with validation XHTML. Search Engine Optimizer advised us that we should change it...
14
by: howa | last post by:
Is it true that if my XHTML is conforming to the w3c XHTML DTD, my XHTML is validated and no need to run the HTML validation hosted on w3c web page? Thanks.
9
tharden3
by: tharden3 | last post by:
My site is HTML Valid by the W3C for all but one error. You see, to make a really great navigation bar in my left column, I added the <p> attribute to the text in-between an <a href=""></a> link...
1
by: =?Utf-8?B?ZGlzY2lwbGluZTRldmVyNjY2?= | last post by:
Hi, the CMS out company wrote a few years ago, uses certain attrbutes not included in any HTML validation known. Is there a way to add these custom attributes to HTML validation within VS2005? I...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.