sulong

<script type="text/javascript">
function btn_praise(txtTypeId) {
var txtRowGuidMain = $("#hide_RowGuidMain").val();
var txtUserId = $("#hide_UserId").val();
if (txtRowGuidMain == \'\' || txtUserId == \'\') {
alert(\'对不起,操作失败!\');
}
else {
$.ajax({
type: "POST", //用POST方式传输
url: \'../AddPriseHandler.ashx\', //目标地址
dataType: "json" ,//需要限定
data: { RowGuidMain: txtRowGuidMain, UserId: txtUserId, TypeId: txtTypeId },
success: function (data) {

//此处返回值假设为{"message":"成功","result":16}

alert(data.message);
$(this).attr("value", data.result)
},
error: function () {
alert("异常!");
}
})
}
};
</script>

分类:

技术点:

相关文章: