话不多说先上代码,
前端的HTML文件中Table部分
<table id="Class_Table" class="table table-hover"></table>
<script>
 $('#Class_Table').bootstrapTable({
    url: "GetClass.jsp",
    method : 'post', // 请求方式(*)post/get
    contentType: "application/x-www-form-urlencoded", 
    queryParams: "queryParams",
    toolbar: "#toolbar",
    sidePagination: "true",
    striped: true, // 是否显示行间隔色
    search : "true",
    uniqueId: "ID",
    pageSize: "5",
    pagination: true, // 是否分页
    sortable: true, // 是否启用排序
    responseHandler:function (res) {
        return res.DATA;
    }, 
    columns: [{
            field: 'cno',
            title: '课程号'
        },
        {
            field: 'cname',
            title: '课程名'
        },
        {
            field: 'credit',
            title: '学分'
        },
        {
            title: '操作',
            width: 120,
            align: 'center',
            valign: 'middle',
            formatter: actionFormatter,
        }    ]
}); //操作栏的格式化
function actionFormatter(value, row, index) {
    var id = value;
    var result = "";
    result += "<a href='javascript:;' class='btn btn-xs green' onclick=\"EditViewById('" + id + "', view='view')\" title='查看'><span class='glyphicon glyphicon-search'></span></a>";
    result += "<a href='javascript:;' class='btn btn-xs blue' onclick=\"EditViewById('" + id + "')\" title='编辑'><span class='glyphicon glyphicon-pencil'></span></a>";
    result += "<a href='javascript:;' class='btn btn-xs red' onclick=\"DeleteByIds('" + id + "')\" title='删除'><span class='glyphicon glyphicon-remove'></span></a>";
    return result;
}
</script>后台的JSP文件
从JavaBean中获取数据库的数据,转为JSON传到JSP文件,然后在输出在页面上
<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ page import="java.util.*"%>
<%@ page import="org.json.*"%>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Insert title here</title>
</head>
<body>
<jsp:useBean id="ClassMessage" class="javabean.ClassMessage" scope="page"/>
<%
JSONArray json = new JSONArray();
json= ClassMessage.getForm();
out.print(json);%> 
</body>
</html>老哥们,要怎么样才能匹配上啊?求助!!!!