Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $(document).ready(function()
- {
- $.ajax({
- url: "http://jsonplaceholder.typicode.com/users",
- type: "POST",
- dataType:"json",
- success: function (response)
- {
- var trHTML = '';
- $.each(response, function (key,value) {
- trHTML +=
- '<tr><td>' + value.id +
- '</td><td>' + value.name +
- '</td><td>' + value.username +
- '</td><td>' + value.email +
- '</td><td>' + value.address +
- '</td><td>' + value.phone +
- '</td><td>' + value.website +
- '</td><td>' + value.company +
- '</td></tr>';
- });
- $('#users').append(trHTML);
- }
- });
- });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement