Text Input Create Events

Description

The textinput create event is triggered when a text input is created.

Example


<!DOCTYPE html>
<html>
<head>
<script src="http://code.jquery.com/jquery-1.6.4.min.js"></script>
<script type='text/javascript'>//<![CDATA[ 
$(function(){<!--from   w  ww . j  a va 2 s .c o  m-->
$(  '<input  type="text" name="text2" id="text2"  value="" />' )
.textinput({
   theme: 'a',
   create:  function(event) {
       console.log(  "Creating text input..." );
   }
}).insertAfter(  "#Input1" );
});//]]>  
</script>
<link rel="stylesheet"
  href="http://code.jquery.com/mobile/1.0/jquery.mobile-1.0.min.css" />

<script src="http://code.jquery.com/mobile/1.0/jquery.mobile-1.0.min.js"></script>
</head>
<body>
  <div data-role="page" id="index">
    <div data-theme="a" data-role="header">
      <h3>First Page</h3>
      <a href="#second" class="ui-btn-right">Next</a>
    </div>
    <div data-role="content">
      <fieldset data-role="controlgroup">
        <input id="Input1" /> 
        <input data-theme="a" />
      </fieldset>
    </div>
    <div data-theme="a" data-role="footer" data-position="fixed"></div>
  </div>


</body>
</html>

Click to view the demo





















Home »
  jQuery Mobile »
    Tutorial »




jQuery_Mobile
Form
List
Layout
Theme