Created
November 30, 2016 05:24
-
-
Save agentready/bddf0cf1d1284bb9ccb95109346c56a0 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<title>jquery</title> | |
<script src="http://cdn.dev/jq/jquery.min.js"></script> | |
</head> | |
<body> | |
<form id="myform"> | |
<input type="text" name="" id="id"> | |
<input type="text" name="" id="email"> | |
<input type="text" name="" id="reg_date"> | |
<input type="text" name="" id="ward"> | |
<input type="submit" value="Save This"> | |
</form> | |
<script type="text/javascript"> | |
var data = [{"id":"52","name":"hayat","email":"hayat.hasan@gmail","password":"123","reg_date":"29-11-16 09:22:22","businesstype":"","phone":"01710","address":"224 B","ward":"ba","village":"bhh","upozilla":"bahhff","district":"dhffvh"}]; | |
$.each(data, function(i, f) { | |
for(k in f){ | |
$('#myform').find("#"+k).val(f[k]); | |
} | |
}); | |
</script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment