Hi naveed1229,
I have created sample code which full-fill your requirement.So please refer the below code.
HTML
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title></title>
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script>
<script type="text/javascript">
$(document).ready(function () {
$(document).on('keyup', 'input[type="text"]', function () {
$(this).attr('value', $(this).val());
});
$('input[type="CheckBox"]').click(function () {
$(this).is(":checked") ? $(this).attr('checked', true) : $(this).attr('checked', false);
});
$('input[type="Radio"]').click(function () {
$(this).is(":checked") ? $(this).attr('checked', true) : $(this).attr('checked', false);
});
$("input#btnSubmit").click(function () {
var markup = document.documentElement.outerHTML;
alert(markup);
});
});
</script>
</head>
<body>
<form id="form1" runat="server">
<div id="div1">
Name:<input type="text" id="txtName" name="txtName" value="" />
<br />
CheckBox:<input type="CheckBox" id="CheckBox1" name="CheckBox1" value="CheckboxValue1" />
<br />
RadioButton:<input type="Radio" id="RadioButton1" name="RadioButton1" value="RadioButtonvalue1" />
<br />
<input type="button" id="btnSubmit" name="name" runat="server" onclick="Submit();"
value="Submit" />
</div>
</form>
</body>
</html>
Demo