jquery mobile validation

<!DOCTYPE html>
<html>
<head>
 <meta http-equiv="content-type" content="text/html; charset=UTF-8">  <title> - jsFiddle demo</title>   <script type='text/javascript' src='http://code.jquery.com/jquery-1.6.4.js'></script>   <link rel="stylesheet" type="text/css" href="/css/normalize.css">    <link rel="stylesheet" type="text/css" href="/css/result-light.css">    <script type='text/javascript' src="http://ajax.aspnetcdn.com/ajax/jquery.validate/1.7/jquery.validate.min.js"></script>     <link rel="stylesheet" type="text/css" href="http://code.jquery.com/mobile/1.0.1/jquery.mobile-1.0.1.css">     <script type='text/javascript' src="http://code.jquery.com/mobile/1.0.1/jquery.mobile-1.0.1.js"></script>    <style type='text/css'>  label.error {  color: red;  font-size: 16px;  font-weight: normal;  line-height: 1.4;  margin-top: 0.5em;  width: 100%;  float: none; }  @media screen and (orientation: portrait){  label.error { margin-left: 0; display: block; } }  @media screen and (orientation: landscape){  label.error { display: inline-block; margin-left: 22%; } }  em { color: red; font-weight: bold; padding-right: .25em; }    </style>    <script type='text/javascript'>//<![CDATA[ $(window).load(function(){ $( "#frmLogin" ).validate({  submitHandler: function( form ) {  alert( "Call Login Action" );  } });  });//]]>  </script>   </head> <body>  <meta name="viewport" content="width=device-width, initial-scale=1">  <div data-role="page" id="login">   <div data-role="header">  <h1>Acme Corporation</h1>  </div>   <div data-role="content">   <form id="frmLogin" class="validate">  <div data-role="fieldcontain">  <label for="email"><em>* </em> Email: </label>  <input type="text" id="email" name="email"  class="required email" />  </div>   <div data-role="fieldcontain">  <label for="password"><em>* </em>Password: </label>  <input type="password" id="password" name="password"  class="required" />  </div>   <div class="ui-body ui-body-b">  <button class="btnLogin" type="submit"  data-theme="a">Login</button>  </div>  </form>   </div>  </div>    </body>   </html> 
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值