好得很程序员自学网

<tfoot draggable='sEl'></tfoot>

juery和ajaxPro结合使用的问题,如内容_html/css_WEB-ITnose

前台:
jQuery(document).ready(function($)
{
$("#div1").mouseover(function() {
alert('ddddddd');
});
$("#btnGetValue").click(function() {

var vUrl = $("#hUrl").val();
$.ajax(
{
type: "POST",
url: vUrl,
data: null,
beforeSend: function(xhr) {
xhr.setRequestHeader("ajaxpro-method", "HelloWorld");
},
success: function(s) {
alert(s);

var a = document.getElementById("div");
a.innerHTML= s;
}

});

});
});







后台:
AjaxPro.Utility.RegisterTypeForAjax(typeof(Default3));
if (!IsPostBack)
{
string path = "/WebSite1/ajaxpro/Default3,";
path += typeof(Default3).Assembly.FullName.Split(',')[0];
path += ".ashx";
hUrl.Value = path;

}
[AjaxPro.AjaxMethod]
public string HelloWorld()
{
return "

aaaa

查看更多关于juery和ajaxPro结合使用的问题,如内容_html/css_WEB-ITnose的详细内容...

  阅读:42次