如何将json值打印到HTML表

时间:2016-03-02 12:27:43

标签: html json ajax

下面是ajax函数,它使用和警告输出数据

ajax功能:

      function load(userType){
          $.ajax({
                type: "POST",
                url: "load.html",
                data: "userType=" + userType,
                success: function(response){
                    alert(response);              
                },
          });   
       }

警报输出:

[{
    "userId":1,
    "email":"jay@gmail.com",
    "mobile":"9900082195",
    "gender":"male",
    "qualification":"1",
    "dob":"1990-01-01",

    "login":{
        "loginId":1,
        "userName":"Jay",
        "password":"Jay",
    }
}]

如何将上面的json警报输出打印到html表?

0 个答案:

没有答案