
Hi Everyone,
Here some snippet code for creating html control dynamically in javascript....
<script type="text/javascript"> function createUserInterface() {
document.write("<form id='form1'>");
document.write("Employee Id : <input type='text' id='tt1' /> <br />");
document.write("Employee Name : <input type='text' id='tt2' /><br />");
document.write("Employee Age : <input type='text' id='tt3' /><br />");
document.write("Employee City : <select id='selectCity'><option value='Allahabd'>Allahabd</option>");
document.write("<option value='Lucknow'>Lucknow</option><option value='Kanpur'>Kanpur</option></select><br />");
document.write("<input type='button' id='btnSubmit' value='Submit' />");
document.write("</form>");
}
</script>
for more details please check out the following link......
http://mindstick.com/Articles/ddeb7a...%20dynamically
Thanks !!!