index.html 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8">
  5. <title>jQuery validation plug-in - requirejs demo</title>
  6. <link rel="stylesheet" href="../css/screen.css">
  7. <style type="text/css">
  8. #commentForm { width: 500px; }
  9. #commentForm label { width: 250px; }
  10. #commentForm label.error, #commentForm input.submit { margin-left: 253px; }
  11. </style>
  12. </head>
  13. <body>
  14. <h1 id="banner"><a href="https://jqueryvalidation.org/">jQuery Validation Plugin</a> Demo</h1>
  15. <div id="main">
  16. <p>Default submitHandler is set to display an alert into of submitting the form</p>
  17. <form class="cmxform" id="commentForm" method="get" action="">
  18. <fieldset>
  19. <legend>Please provide your name, email address (won't be published) and a comment</legend>
  20. <p>
  21. <label for="cname">Name (required, at least 2 characters)</label>
  22. <input id="cname" name="name" minlength="2" type="text" required>
  23. </p>
  24. <p>
  25. <label for="cemail">E-Mail (required)</label>
  26. <input id="cemail" type="email" name="email" required>
  27. </p>
  28. <p>
  29. <label for="curl">URL (optional)</label>
  30. <input id="curl" type="url" name="url">
  31. </p>
  32. <p>
  33. <label for="ccomment">Your comment (required)</label>
  34. <textarea id="ccomment" name="comment" required></textarea>
  35. </p>
  36. <p>
  37. <input class="submit" type="submit" value="Submit">
  38. </p>
  39. </fieldset>
  40. </form>
  41. <script>
  42. var require = {
  43. paths: {
  44. "jquery": "../../lib/jquery-3.1.1"
  45. }
  46. };
  47. </script>
  48. <script src="../../lib/require.js" data-main="app.js"></script>
  49. </div>
  50. </body>
  51. </html>