0
我使用$ .post请求并返回一些数据。我想打印这些数据(在纸上!)。我在JavaScript中的代码是:
$('#printDamages').click(function(){
var printDmgs = [];
$.each($("input[name='chk_group']:checked"), function(){
printDmgs.push($(this).val());
});
$.post('ajax_Print_Damages.php',
{
inner : JSON.stringify(printDmgs)
},
function(data){
window.print(); //I tried this but ofcourse is printing current window
}
);
});
有没有人提出建议?
谢谢!!正是我所需要的! – 2014-09-22 22:37:56