本文介绍了从我的弹出窗口传递值时,ashx页面没有调用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述 29岁程序员,3月因学历无情被辞! 嗨朋友们, 我使用以下代码动态创建编辑按钮动态按钮。Hi Friends,I created edit button dynamically button dynamically with the following code.ed = "<input style='height:22px;width:55px;' type='button' value='Edit' onclick=\"editSection('" + last_row + "');\" />"; 我正在调用editSection(rowToBeEdited)函数and i am calling editSection(rowToBeEdited) functionfunction editSection(secIndex) { alert("edit row="+secIndex); var userid= $("#UserID").val(''); $("#UserName").val(''); var myGrid = $("#UsersGrid"); $("#UserName").val(myGrid.jqGrid('getCell', secIndex, 'UserName')); $("#btnUpdate").css("display", 'inline'); $("#POPUP").dialog({ width: 400 });} 我正在显示弹出数据是and i am displaying the popup data is<table id="UsersGrid"></table> <div id="UsersGridPager"></div><form id="commentForm" runat="server"> <div id="POPUP" style="display:none;"> <fieldset> <p> <label for="UserName">User Name:</label> <input id="UserName" name="UserName" size="25" class="required" /> </p> <p> <input id="btnUpdate" type="button" value="Update" önclick="saveEditedData()" />  <input id="cancel" type="button" value="Cancel" önclick="cancelChanges()" /> </p> </fieldset> </div></form> 更新按钮点击我正在呼叫 saveEditedData ()on update button click i am calling the saveEditedData()function saveEditedData(){ var userName = $("#UserName"); $.ajax({ url: "editRow.ashx?UserID=" + 9 + "&UserName=" + UserName.val(), cache: false, crossDomain: true, dataType: "jsonp" }).done(function (secIndex) { // handle the output here alert(secIndex.Response.id + " is edited "); $("#UsersGrid").trigger("reloadGrid"); }); $("#POPUP").dialog('close');}function cancelChanges(){ // alert("closed"); $("#POPUP").dialog('close');} 主要问题是我传递的价值如url:editRow.ashx?UserID =+ 9 + & UserNe ame =+ UserName.val(), editRow.ashx 未调用? 如何从 ashx 页面获取此日期?The main problem is when i am passing value like url: "editRow.ashx?UserID=" + 9 + "&UserNe ame=" + UserName.val(), the editRow.ashx is not calling ?How can I get this date from ashx page?推荐答案 这篇关于从我的弹出窗口传递值时,ashx页面没有调用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 上岸,阿里云!
08-30 22:19