Click here to Skip to main content
15,886,545 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
How to create textfield in the form using JQuery
Posted

 
Share this answer
 
Try this,

JavaScript
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script>


JavaScript
<script language="javascript" type="text/javascript">

            $(function () {

                             alert($("#div2").html());
                             $("#div2").html("<input type='text' id='textbox1' value='Hello!!' />");
                   });


HTML
<div id="div2"></div>
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900