function shua(){
var str = "";
var tbody=window.document.getElementById("table1");
var next=$("#number").html();
var url = "\" __ROOT__/index.php/Home/Index/play?id=";
$.post(
'__ROOT__/index.php/Home/Actor/shua',
{next:next,genresid:{$genresid}},
function(msg){
var data = msg.data;
var url="\"__ROOT__/index.php/Home/Index/video?id=";
for (i in data) {
str += "<tr>" +
"<td><a href=" + url + data[i].id + "\"><img src=" + data[i].cover +" /></a></td>" +
"</tr>"
;
}
tbody.append(str);
$("#number").text(msg.next);
}
)
}
在列表最后追加的确是文本格式,图片不显示。
$("#number").text(msg.next); -> $("#number").html(msg.next);